summaryrefslogtreecommitdiff
path: root/src/resolve-names.cc
diff options
context:
space:
mode:
authorShravan Narayan <shravanrn@gmail.com>2023-06-20 00:06:25 -0400
committerShravan Narayan <shravanrn@gmail.com>2023-07-02 07:33:45 -0400
commite37de9dedfc7037cea09ca3c75fd5a544d68cb2a (patch)
tree11892c752279c0cc869c2ba07436f777d904dc46 /src/resolve-names.cc
parent6f58973e2680b71e56a41f798d6072208c721a12 (diff)
downloadwabt-e37de9dedfc7037cea09ca3c75fd5a544d68cb2a.tar.gz
wabt-e37de9dedfc7037cea09ca3c75fd5a544d68cb2a.tar.bz2
wabt-e37de9dedfc7037cea09ca3c75fd5a544d68cb2a.zip
C++20 compatibility fixes
Diffstat (limited to 'src/resolve-names.cc')
-rw-r--r--src/resolve-names.cc12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/resolve-names.cc b/src/resolve-names.cc
index 9f0b3b02..b4355350 100644
--- a/src/resolve-names.cc
+++ b/src/resolve-names.cc
@@ -488,12 +488,12 @@ void NameResolver::VisitFunc(Func* func) {
ResolveFuncTypeVar(&func->decl.type_var);
}
- func->bindings.FindDuplicates(
- [=](const BindingHash::value_type& a, const BindingHash::value_type& b) {
- const char* desc =
- (a.second.index < func->GetNumParams()) ? "parameter" : "local";
- PrintDuplicateBindingsError(a, b, desc);
- });
+ func->bindings.FindDuplicates([func, this](const BindingHash::value_type& a,
+ const BindingHash::value_type& b) {
+ const char* desc =
+ (a.second.index < func->GetNumParams()) ? "parameter" : "local";
+ PrintDuplicateBindingsError(a, b, desc);
+ });
visitor_.VisitFunc(func);
current_func_ = nullptr;