cprover
bv_endianness_map.h
Go to the documentation of this file.
1 /*******************************************************************\
2 
3 Module:
4 
5 Author: Michael Tautschnig
6 
7 \*******************************************************************/
8 
9 #ifndef CPROVER_SOLVERS_FLATTENING_BV_ENDIANNESS_MAP_H
10 #define CPROVER_SOLVERS_FLATTENING_BV_ENDIANNESS_MAP_H
11 
12 #include <util/endianness_map.h>
13 
14 class boolbv_widtht;
15 
21 {
22 public:
24  const typet &type,
25  bool little_endian,
26  const namespacet &_ns,
27  boolbv_widtht &_boolbv_width)
28  : endianness_mapt(_ns), boolbv_width(_boolbv_width)
29  {
30  build(type, little_endian);
31  }
32 
33 protected:
35 
36  virtual void build_little_endian(const typet &type) override;
37  virtual void build_big_endian(const typet &type) override;
38 };
39 
40 #endif // CPROVER_SOLVERS_FLATTENING_BV_ENDIANNESS_MAP_H
The type of an expression.
Definition: type.h:22
Maps a big-endian offset to a little-endian offset.
bv_endianness_mapt(const typet &type, bool little_endian, const namespacet &_ns, boolbv_widtht &_boolbv_width)
void build(const typet &type, bool little_endian)
boolbv_widtht & boolbv_width
TO_BE_DOCUMENTED.
Definition: namespace.h:74
virtual void build_little_endian(const typet &type) override
virtual void build_big_endian(const typet &type) override
Map bytes according to the configured endianness.