Re: g_value_ types ...
- From: Tim Janik <timj gtk org>
- To: Owen Taylor <otaylor redhat com>
- Cc: Gtk+ Developers <gtk-devel-list gnome org>,	Michael Meeks <michael ximian com>
- Subject: Re: g_value_ types ...
- Date: Tue, 8 May 2001 19:04:53 +0200 (CEST)
On 3 May 2001, Owen Taylor wrote:
> 
> Can we back up here and get some context here about what you
> want these types for?
> 
> I think all of these could be done with G_TYPE_BOXED - using
> a new fundemental type is just a small efficiency win and
> for a lot of things will be lost in the noise.
> 
> [
>  Actually, I'm quite opposed to the idea of reserving type IDs, it's
>  setting us up for pain, and if people really register their ideas, we
>  could could easily run out of space in the registry; I think the right
>  way to handle this is to simply have a g_type_register_fundemental().
to put this into perspective, we have had a dynamically working
g_type_register_fundemental() right from the start.
registering an ID just provides the additional benefit of having a
constant that you can switch (G_TYPE_FUNDAMENTAL (type)) on with
case statements which require constant expressions.
>  Yes, it's a tiny bit slower to use a global variable to store
>  your fundemental type than a constant. I don't think
>  this is worth worrying about
> ]
> 
> 
> Regards,
>                                         Owen
> 
---
ciaoTJ
[
Date Prev][
Date Next]   [
Thread Prev][
Thread Next]   
[
Thread Index]
[
Date Index]
[
Author Index]