sammine-lang
Loading...
Searching...
No Matches
TypeConverter.h
Go to the documentation of this file.
1#pragma once
2#include "lex/Token.h"
3#include "typecheck/Types.h"
4#include "util/Utilities.h"
5#include <llvm/IR/Instructions.h>
6#include <llvm/IR/LLVMContext.h>
7#include <llvm/IR/Type.h>
8
12namespace sammine_lang::AST {
13class TypeConverter {
14
15 llvm::LLVMContext &context;
16
17public:
18 llvm::Type *get_type(Type t);
19 llvm::Type *get_return_type(Type t);
20 llvm::CmpInst::Predicate get_cmp_func(Type a, Type b, TokenType tok);
21
22 TypeConverter(llvm::LLVMContext &context) : context(context) {}
23};
24} // namespace sammine_lang::AST
Defines the token structure (TokenType, TokStream, TokenMap)
Defines the core Type system for Sammine.
Holds classes and functionalities for dealing with Error handling, source locations caching & indexin...
Definition Types.h:45