|
Boost Users : |
Subject: Re: [Boost-users] sizeof of boost::int8_t
From: John Maddock (john_at_[hidden])
Date: 2009-12-16 11:55:21
> running sizeof on a boost::int8_t returns 1, but what is the type?
> int/char?
Strictly speaking you're not allowed to ask that question... it's a secret
:-)
The idea is that int8_t is whatever platform-dependent type has 8-bits and
is signed.
But since you ask, it's "signed char" on any platform you're ever likely to
encounter. You should never make any assumptions about the actual types of
the int#_t typedefs though - some of them really are "unmentionable"
platform dependent types on some platforms - but take a look at
boost/cstdint.hpp for the details.
HTH, John.
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net