Re: non-64bit platforms? (Re: g[u]int64 GValues (was GValue questions))



Pavel Machek wrote:
> 
> > > > right, but afaik, 64bit ints are not supported on all system/compiler versions
> > > > that glob runs on. at least historically this has been an issue, which is why
> > > > we special-case guint64 definitions in glib based on a configure.in check.
> > > > i'm not quite sure where 64bit ints fail nowadays though, irrc, orbit
> > > > has a hard dependancy on 64bit ints for quite some time now and runs on a
> > > > bunch of systems.
> > >
> > > Midnight commander (even text edition) depends on glib, and it really
> > > wants to be portable to obscure systems... Try to ask on mc-devel if
> > > all platforms do have 64-bit integers...
> >
> > All**1 platforms with gcc do. And practicly all 'long long' using code out
> > there relies on it being 64 bits, so it's unlikely that gcc ports would
> > use some other size for it.
> 
> I'm afraid that mc is use even on platforms that lack gcc... This
> still might be a problem.

To summarize: If glib wants to support mc on all platforms, glib can't
have unconditional 64-bit int support.

But I suppose that many users of glib don't care about platforms
without gcc (or another compiler supporting 64-bit ints) *at all*,
and would welcome the inclusion of 64-bit int support in glib,
depending on G_HAVE_GINT64.

What counts is that people who want to write truely portable
software using glib can continue to do so. And that people who don't
care about portability to exotic platforms are not withheld
from using basic capabilities of their platform with full
glib support.

IOW, I want G_TYPE_[U]INT64 and G_TYPE_PARAM_[u]INT. I currently
have to work around a few cases where I wanted to pass 64-bit ints
as signal paramters.


Regards,
Johannes




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]