summaryrefslogtreecommitdiff
path: root/src/resolve-names.cc
diff options
context:
space:
mode:
authorSam Clegg <sbc@chromium.org>2019-11-07 18:42:51 -0800
committerGitHub <noreply@github.com>2019-11-07 18:42:51 -0800
commit2e2991e5a0e6a75d57c9ed6ff7ee0ae88adf253f (patch)
tree724bddd7110147c66163e6f230d4456e1e1e870f /src/resolve-names.cc
parent2561eaca9cdba262eaa1e74ce877ffc7be543323 (diff)
downloadwabt-2e2991e5a0e6a75d57c9ed6ff7ee0ae88adf253f.tar.gz
wabt-2e2991e5a0e6a75d57c9ed6ff7ee0ae88adf253f.tar.bz2
wabt-2e2991e5a0e6a75d57c9ed6ff7ee0ae88adf253f.zip
Initial implementation of reftype proposal in the interpreter. (#1206)
- Implement ref.func everywhere. - Implement table.get and table.set in the interpreter.
Diffstat (limited to 'src/resolve-names.cc')
-rw-r--r--src/resolve-names.cc6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/resolve-names.cc b/src/resolve-names.cc
index 0e3c70e1..6eef0685 100644
--- a/src/resolve-names.cc
+++ b/src/resolve-names.cc
@@ -63,6 +63,7 @@ class NameResolver : public ExprVisitor::DelegateNop {
Result OnTableSetExpr(TableSetExpr*) override;
Result OnTableGrowExpr(TableGrowExpr*) override;
Result OnTableSizeExpr(TableSizeExpr*) override;
+ Result OnRefFuncExpr(RefFuncExpr*) override;
Result BeginTryExpr(TryExpr*) override;
Result EndTryExpr(TryExpr*) override;
Result OnThrowExpr(ThrowExpr*) override;
@@ -377,6 +378,11 @@ Result NameResolver::OnTableSizeExpr(TableSizeExpr* expr) {
return Result::Ok;
}
+Result NameResolver::OnRefFuncExpr(RefFuncExpr* expr) {
+ ResolveFuncVar(&expr->var);
+ return Result::Ok;
+}
+
Result NameResolver::BeginTryExpr(TryExpr* expr) {
PushLabel(expr->block.label);
ResolveBlockDeclarationVar(&expr->block.decl);