cprover
ansi_c_convert_type.h
Go to the documentation of this file.
1 /*******************************************************************\
2 
3 Module: ANSI-C Language Conversion
4 
5 Author: Daniel Kroening, kroening@kroening.com
6 
7 \*******************************************************************/
8 
11 
12 #ifndef CPROVER_ANSI_C_ANSI_C_CONVERT_TYPE_H
13 #define CPROVER_ANSI_C_ANSI_C_CONVERT_TYPE_H
14 
15 #include <list>
16 
17 #include <util/message.h>
18 
19 #include "c_qualifiers.h"
20 #include "c_storage_spec.h"
21 
23 {
24 public:
29 
30  // extensions
40 
42 
43  bool packed, aligned;
45  exprt msc_based; // this is Visual Studio
47 
48  // storage spec
50 
51  // qualifiers
53 
54  virtual void read(const typet &type);
55  virtual void write(typet &type);
56 
58 
59  std::list<typet> other;
60 
61  explicit ansi_c_convert_typet(message_handlert &_message_handler):
62  messaget(_message_handler)
63  // class members are initialized by calling read()
64  {
65  }
66 
67  virtual void clear()
68  {
84 
86 
87  other.clear();
90  }
91 
92 protected:
93  virtual void read_rec(const typet &type);
94  virtual void build_type_with_subtype(typet &type) const;
95  virtual void set_attributes(typet &type) const;
96 };
97 
98 #endif // CPROVER_ANSI_C_ANSI_C_CONVERT_TYPE_H
virtual void read_rec(const typet &type)
ansi_c_convert_typet(message_handlert &_message_handler)
c_storage_spect c_storage_spec
virtual void read(const typet &type)
virtual void write(typet &type)
virtual void set_attributes(typet &type) const
Add qualifiers and GCC attributes onto type.
source_locationt source_location
virtual void build_type_with_subtype(typet &type) const
Build a vector or complex type with type as subtype.
std::list< typet > other
virtual void clear() override
Definition: c_qualifiers.h:79
Base class for all expressions.
Definition: expr.h:54
void make_nil()
Definition: irep.h:464
Class that provides messages with a built-in verbosity 'level'.
Definition: message.h:155
The type of an expression, extends irept.
Definition: type.h:28