Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Pascal Misc > Re: size proble...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 3 of 7 Topic 714 of 811
Post > Topic >>

Re: size problems when casting integer onto set in gpc

by Jonas Maebe <Jonas.Maebe@[EMAIL PROTECTED] > Jan 26, 2007 at 02:44 PM

In article <1169818742.745928.231770@[EMAIL PROTECTED]
>,
 "southwesthustla" <fdkelly@[EMAIL PROTECTED]
> wrote:

> I note that in (MinGW) gpc a 'set' is internally a multiple of 4 bytes
> long. I would like to cast a 16-bit unsigned integer (i.e. size of 2
> bytes) onto a 16-element set. This should be possible, if the set was
> allowed to be 2 bytes long also.

Apart from the size difference, it's also quite possible that the 
internal format of a set is different in GPC than in the previous 
compiler you were using. Sets are generally opaque types, and depending 
on them having a particular format is a bad thing.

It's better to rewrite your program in a way so it does not depend on 
the internal format of sets, otherwise you'll run again into problems 
when GPC changes its internal set representation (which isn't unlikely, 
from what I've understood -- although it might be limited to big endian 
systems).


Jonas
 




 7 Posts in Topic:
size problems when casting integer onto set in gpc
"southwesthustla&quo  2007-01-26 05:39:02 
Re: size problems when casting integer onto set in gpc
"southwesthustla&quo  2007-01-26 05:43:12 
Re: size problems when casting integer onto set in gpc
Jonas Maebe <Jonas.Mae  2007-01-26 14:44:02 
Re: size problems when casting integer onto set in gpc
Waldek Hebisch <hebisc  2007-01-26 14:57:43 
Re: size problems when casting integer onto set in gpc
"southwesthustla&quo  2007-01-30 07:46:34 
Re: size problems when casting integer onto set in gpc
Waldek Hebisch <hebisc  2007-01-30 18:16:00 
Re: size problems when casting integer onto set in gpc
"southwesthustla&quo  2007-01-31 06:13:11 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sat Jul 26 6:05:44 CDT 2008.