Implements indexing with period identifier style (`foo.bar`)
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
@@ -41,6 +41,10 @@ public:
|
||||
throw EvaluationException("Can't index this EvalValue");
|
||||
}
|
||||
|
||||
virtual shared_ptr<EvalValue> IndexValue(uint32_t hash){
|
||||
throw EvaluationException("Can't index this EvalValue");
|
||||
}
|
||||
|
||||
virtual void SetIndexValue(EvalValue *key, shared_ptr<EvalValue> value){
|
||||
throw EvaluationException("Can't index this EvalValue");
|
||||
}
|
||||
|
||||
@@ -41,6 +41,10 @@ public:
|
||||
return this -> _table->at(hash);
|
||||
}
|
||||
|
||||
shared_ptr<EvalValue> IndexValue(uint32_t hash) final{
|
||||
return this -> _table->at(hash);
|
||||
}
|
||||
|
||||
shared_ptr<EvalValue> IndexValue(const char* val){
|
||||
auto hash = HashedString::ConstHash(val);
|
||||
return this -> _table -> at(hash);
|
||||
|
||||
Reference in New Issue
Block a user