This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: unsigned long long int ????
>>>>> "Suni" == Suni B Bongale <sbongale@nulinkinc.com> writes:
Suni> The version number of the gcc that I am using is gcc version
Suni> 2.95.4 I have written a macro in the follwing source code to
Suni> retrieve a unsigned long long value form a character array
Suni> But when I compiled the code its giving error.
It's giving errors because of unbalanced parenthesis. You have more
opening parenthesis than closing ones in your macro definition.
You should really use an editor which shows you the extent of your
parens (Emacs is good ;-).
I suppose what you wanted was something like:
#define GTP_GET_U64BIT(p_buff) (unsigned long long) \
(((U64bit)(*(p_buff)) << 56) | \
((U64bit)((*(p_buff + 1))) << 48) | \
((U64bit)((*(p_buff + 2))) << 40) | \
((U64bit)((*(p_buff + 3))) << 32) | \
((U64bit)((*(p_buff + 4))) << 24) | \
((U64bit)((*(p_buff + 5))) << 16) | \
((U64bit)((*(p_buff + 6))) << 8) | \
((U64bit)((*(p_buff + 7)))))
--
Claudio Bley _
ASCII ribbon campaign ( )
ICQ# 83197241 - against HTML email X
http://www.cs.uni-magdeburg.de/~bley/ & vCards / \