Boost logo

Boost Users :

Subject: [Boost-users] [conversion] Is there a boost lib for converting octet array to integral types?
From: Mostafa (mostafa_working_away_at_[hidden])
Date: 2010-07-08 15:41:01

Hi all,

Is there a boost utility for converting an array of octets to an integral
type? Something along the lines of:

boost::uint8_t const octetBuf[] = {0x23, 0x4e};
boost::uint32_t const thirtyTwoBit = some_function(octetBuf);

Where some_function takes care of the padding based on endianness.



Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at