|
Xreate
The Xreate programming language
|
Type inference support. More...
Functions | |
| llvm::Value * | doAutomaticTypeConversion (llvm::Value *source, llvm::Type *tyTarget, llvm::IRBuilder<> &builder) |
| Casts the given variable to the given type. More... | |
| ExpandedType | getType (const Expression &expression, const AST &ast) |
| Performs basic type inference to deduce the type of the given expression. More... | |
Type inference support.
| llvm::Value * doAutomaticTypeConversion | ( | llvm::Value * | source, |
| llvm::Type * | tyTarget, | ||
| llvm::IRBuilder<> & | builder | ||
| ) |
Casts the given variable to the given type.
| source | The variable that needs casting |
| tyTarget | The type to cast to |
| builder | Instance of llvm's IRBuilder |
| ExpandedType getType | ( | const Expression & | expression, |
| const AST & | ast | ||
| ) |
Performs basic type inference to deduce the type of the given expression.
Tries several strategies in the following order:
| expression | Infers the given expression's type. |
| ast | AST instance. |
1.8.14