T
Tagore
I checked ctype.h header file to see how isupper macro is defined in
it. I foung following implementation:
#define isupper(c) (_ctype[(c) + 1] & _IS_UPP)
where _IS_UPP is defined as:
#define _IS_UPP 4
please help me in understanding working of it.
Actually I was trying to define my own macro for isupper as
#define isupper(c) (((c) >= 'A') && ((c) <= 'Z')))
but it would create problem if I call it as isupper(ch++)..
so I tried to understand how it is defined in ctype.h and could not
understand its working.
it. I foung following implementation:
#define isupper(c) (_ctype[(c) + 1] & _IS_UPP)
where _IS_UPP is defined as:
#define _IS_UPP 4
please help me in understanding working of it.
Actually I was trying to define my own macro for isupper as
#define isupper(c) (((c) >= 'A') && ((c) <= 'Z')))
but it would create problem if I call it as isupper(ch++)..
so I tried to understand how it is defined in ctype.h and could not
understand its working.