Implements basic numerical tables
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2019-06-09 20:15:09 +02:00
parent ec2419bc7d
commit 081def0be0
21 changed files with 324 additions and 24 deletions

View File

@@ -35,7 +35,9 @@ public:
throw EvaluationException("Can't evaluate this EvalValue as string.");
}
virtual EvalValue* IndexValue(EvalValue* val){
virtual std::size_t GetHashCode() = 0;
virtual shared_ptr<EvalValue> IndexValue(EvalValue* val){
throw EvaluationException("Can't index this EvalValue");
}
};
@@ -66,6 +68,10 @@ public:
return false;
return this->EvaluateBool() == b->EvaluateBool();
};
std::size_t GetHashCode() final{
return _value;
}
};
#endif //PORYGONLANG_EVALVALUE_HPP