Added ValueType class
This commit is contained in:
@@ -1,29 +1,16 @@
|
||||
#include "Parser/Statement/StatementMetaExternFunction.h"
|
||||
|
||||
static string valueTypeToString(ValueType valueType) {
|
||||
switch (valueType) {
|
||||
case ValueType::NONE:
|
||||
return "NONE";
|
||||
case ValueType::BOOL:
|
||||
return "BOOL";
|
||||
case ValueType::SINT32:
|
||||
return "SINT32";
|
||||
case ValueType::REAL32:
|
||||
return "REAL32";
|
||||
}
|
||||
}
|
||||
|
||||
StatementMetaExternFunction::StatementMetaExternFunction(string name, vector<pair<string, ValueType>> arguments, ValueType returnValueType):
|
||||
StatementMetaExternFunction::StatementMetaExternFunction(string name, vector<pair<string, shared_ptr<ValueType>>> arguments, shared_ptr<ValueType> returnValueType):
|
||||
Statement(StatementKind::META_EXTERN_FUNCTION), name(name), arguments(arguments), returnValueType(returnValueType) { }
|
||||
|
||||
string StatementMetaExternFunction::getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
vector<pair<string, ValueType>> StatementMetaExternFunction::getArguments() {
|
||||
vector<pair<string, shared_ptr<ValueType>>> StatementMetaExternFunction::getArguments() {
|
||||
return arguments;
|
||||
}
|
||||
|
||||
ValueType StatementMetaExternFunction::getReturnValueType() {
|
||||
shared_ptr<ValueType> StatementMetaExternFunction::getReturnValueType() {
|
||||
return returnValueType;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user