Make addr me: Self* work for interface methods. (#2374)

Fixes #2223.
This commit is contained in:
Richard Smith
2022-11-07 08:11:19 -08:00
committed by GitHub
parent 9e8cacae00
commit e557d4af3b
9 changed files with 118 additions and 38 deletions
+1 -1
View File
@@ -59,7 +59,7 @@ static auto GetMember(Nonnull<Arena*> arena, Nonnull<const Value*> v,
mem_decl.has_value()) {
const auto& fun_decl = cast<FunctionDeclaration>(**mem_decl);
if (fun_decl.is_method()) {
return arena->New<BoundMethodValue>(&fun_decl, v,
return arena->New<BoundMethodValue>(&fun_decl, me_value,
&impl_witness->bindings());
} else {
// Class function.