Big-endian so that lexicographic array comparison is equivalent to integer comparison
| 168 | // Big-endian so that lexicographic array comparison is equivalent to integer |
| 169 | // comparison |
| 170 | eh_index ArrayToEhIndex(const unsigned char* array) |
| 171 | { |
| 172 | BOOST_STATIC_ASSERT(sizeof(eh_index) == 4); |
| 173 | eh_index bei; |
| 174 | memcpy(&bei, array, sizeof(eh_index)); |
| 175 | return be32toh(bei); |
| 176 | } |
| 177 | |
| 178 | eh_trunc TruncateIndex(const eh_index i, const unsigned int ilen) |
| 179 | { |
no test coverage detected