Added Type class, bettered types a bit, made address of and dereference operators work.

This commit is contained in:
Nathan Braswell
2013-12-23 01:26:24 -06:00
parent 935cc6f968
commit 15674fec2a
10 changed files with 207 additions and 106 deletions

29
include/Type.h Normal file
View File

@@ -0,0 +1,29 @@
#ifndef TYPE_H
#define TYPE_H
#ifndef NULL
#define NULL 0
#endif
#include <string>
#include <iostream>
#include "util.h"
enum ValueType {none, void_type, boolean, integer, floating, double_percision, character };
class Type {
public:
Type();
Type(ValueType typeIn, int indirectionIn);
Type(ValueType typeIn);
Type(std::string typeIn);
~Type();
std::string toString();
ValueType baseType;
int indirection;
private:
};
#endif