ROSE  0.11.145.0
Type.h
1 // WARNING: Changes to this file must be contributed back to Sawyer or else they will
2 // be clobbered by the next update from Sawyer. The Sawyer repository is at
3 // https://github.com/matzke1/sawyer.
4 
5 
6 
7 
8 #ifndef Sawyer_Type_H
9 #define Sawyer_Type_H
10 
11 #include <boost/cstdint.hpp>
12 
13 namespace Sawyer {
14 
16 namespace Type {
17 
19 template<size_t nBits> struct Integer {};
20 template<> struct Integer<8> { typedef boost::int8_t type; };
21 template<> struct Integer<16> { typedef boost::int16_t type; };
22 template<> struct Integer<32> { typedef boost::int32_t type; };
23 template<> struct Integer<64> { typedef boost::int64_t type; };
24 
26 template<size_t nBits> struct UnsignedInteger {};
27 template<> struct UnsignedInteger<8> { typedef boost::uint8_t type; };
28 template<> struct UnsignedInteger<16> { typedef boost::uint16_t type; };
29 template<> struct UnsignedInteger<32> { typedef boost::uint32_t type; };
30 template<> struct UnsignedInteger<64> { typedef boost::uint64_t type; };
31 
32 } // namespace
33 } // namespace
34 
35 #endif
Name space for the entire library.
Definition: FeasiblePath.h:767
A signed integer of particular size.
Definition: Type.h:19
An unsigned integer of particular size.
Definition: Type.h:26