souffle
2.0.2-371-g6315b36
|
Aggregates types using sums and products. More...
#include <TypeSystem.h>
Data Structures | |
struct | Branch |
Public Member Functions | |
const std::vector< Branch > & | getBranches () const |
Return the branches as a sorted vector. More... | |
const std::vector< const Type * > & | getBranchTypes (const std::string &constructor) const |
void | print (std::ostream &out) const override |
void | setBranches (std::vector< Branch > bs) |
Public Member Functions inherited from souffle::ast::analysis::Type | |
const QualifiedName & | getName () const |
const TypeEnvironment & | getTypeEnvironment () const |
bool | operator!= (const Type &other) const |
bool | operator< (const Type &other) const |
bool | operator== (const Type &other) const |
Type (const Type &other)=delete | |
virtual | ~Type ()=default |
Private Member Functions | |
AlgebraicDataType (const TypeEnvironment &env, QualifiedName name) | |
Private Attributes | |
std::vector< Branch > | branches |
Friends | |
class | TypeEnvironment |
Additional Inherited Members | |
Protected Member Functions inherited from souffle::ast::analysis::Type | |
Type (const TypeEnvironment &environment, QualifiedName name) | |
Protected Attributes inherited from souffle::ast::analysis::Type | |
const TypeEnvironment & | environment |
A reference to the type environment this type is associated to. More... | |
QualifiedName | name |
Aggregates types using sums and products.
Invariant: branches are in stored in lexicographical order.
Definition at line 199 of file TypeSystem.h.
|
inlineprivate |
Definition at line 236 of file TypeSystem.h.
|
inline |
Return the branches as a sorted vector.
Definition at line 231 of file TypeSystem.h.
|
inline |
Definition at line 222 of file TypeSystem.h.
|
inlineoverridevirtual |
Reimplemented from souffle::ast::analysis::Type.
Definition at line 211 of file TypeSystem.h.
|
inline |
|
friend |
Definition at line 238 of file TypeSystem.h.
|
private |
Definition at line 240 of file TypeSystem.h.
Referenced by souffle::ast::analysis::AlgebraicDataType::Branch::print(), and setBranches().