expr
expr copied to clipboard
Support fetch using interface
Hi!
Is it possible to provide a Getter interface for fetch ops?
type Getter interface {
Get(key string) (interface{}, bool)
}
Env = map[string]interface{}{
"ctx": getter,
}
Then expression can be more simple
ctx.value_want_to_get
instead of using function
get_value("value_want_to_get")