I believe GCC will compile 'appl' correctly. I use
#define AppType ( 'appl' )
all the time in GCC source at home.
Besides GCC shouldn't have an Intel bias...it's designed for all kindsa
unices, not just Intel ones...
Stuart Nicholson
Programmer
Firepad Inc.
> ----------
> From: Richard Hartman
> Reply To: Palm Developer Forum
> Sent: Wednesday, July 19, 2000 9:45 AM
> To: Palm Developer Forum
> Subject: Re: type 'appl' not ANSI-C. what's the transtaion to
> UInt32 ?
>
>
>
> Ben Combee wrote in message <17945@palm-dev-forum>...
> >
> >"Avi Halachmi" <[EMAIL PROTECTED]> wrote in message
> >news:17894@palm-dev-forum...
> >>
> >> hi.
> >> i want to create a textual ini file with types and creators of
> certain
> >> applications.
> >>
> >> however, the type and creator are defined as (i.e. 'appl') single
> quoted
> 4
> >> chars sequence.
> >> this is leagal in ansi-c, but implementation dependant. i know it
> >transforms
> >> to UInt32 in codeWarrior.
> >
> >You can replace it with this macro
> >
> >#define FourByte(a,b,c,d) ((UInt32)((a) << 24 + (b) << 16 + (c) << 8
> +
> >(d)))
> >
> >then rather than saying 'appl', you'd say FourByte('a','a','p','l').
>
> I am sure that he meant "FourByte('a','p','p','l')"
>
> >
> >CodeWarrior always treats the multi-byte char constants as if they
> were in
> >most-significant-byte-first order due to its Macintosh roots.
> >
>
> You could also use hex literals, if you are comfortable with them.
> The hex literal for 'appl' would be 0x6170706C.
>
> Now CW treats 'appl' correctly ... but what about GCC? Does
> it reveal it's Intel bias there? Does 'appl' even compile w/ GCC?
>
>
>
>
> --
> -Richard M. Hartman
> [EMAIL PROTECTED]
>
> 186,000 mi/sec: not just a good idea, it's the LAW!
>
>
>
>
> --
> For information on using the Palm Developer Forums, or to unsubscribe,
> please see http://www.palmos.com/dev/tech/support/forums/
>
>
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palmos.com/dev/tech/support/forums/