post.x = y defines metadata tag x
This commit is contained in:
parent
5a615ec680
commit
322d55823e
2 changed files with 9 additions and 0 deletions
|
|
@ -398,6 +398,13 @@ value_t get_comment(item_t& item)
|
|||
}
|
||||
}
|
||||
|
||||
void item_t::define(const symbol_t::kind_t, const string& name,
|
||||
expr_t::ptr_op_t def)
|
||||
{
|
||||
bind_scope_t bound_scope(*scope_t::default_scope, *this);
|
||||
set_tag(name, def->calc(bound_scope));
|
||||
}
|
||||
|
||||
expr_t::ptr_op_t item_t::lookup(const symbol_t::kind_t kind,
|
||||
const string& name)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -216,6 +216,8 @@ public:
|
|||
return _state;
|
||||
}
|
||||
|
||||
virtual void define(const symbol_t::kind_t, const string&,
|
||||
expr_t::ptr_op_t);
|
||||
virtual expr_t::ptr_op_t lookup(const symbol_t::kind_t kind,
|
||||
const string& name);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue