unsigned specifier

   
unsigned specifier Unsigned integer type specifier

  simple-type-specifier  := unsigned 

The unsigned type specifier can be used with any integral type to make the type unsigned. Unsigned integer arithmetic is always performed modulo 2 n , in which n is the number of bits in the value representation of the integer. When used alone, unsigned means unsigned int .

Example

 char c; if (isalpha(static_cast<  unsigned char  >(c))   handle_alpha(c); 

See Also

char , int , long , short , signed , type , Chapter 2

   


C++ in a Nutshell
C++ in a Nutshell
ISBN: 059600298X
EAN: 2147483647
Year: 2005
Pages: 270
Authors: Ray Lischner

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net