From: Juha Pohjalainen Subject: [PATCH] Fixing problem with private method lookup. Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Changes are: * two conditionals into vm/builtin_sendsite.cpp Fixes tests: * TestTask::test_locate_method_on_private_private_send Notes: * might not be optimal solution, but gives idea what went wrong --- vm/builtin_sendsite.cpp | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/vm/builtin_sendsite.cpp b/vm/builtin_sendsite.cpp index ff2f9b0..59e5c01 100644 --- a/vm/builtin_sendsite.cpp +++ b/vm/builtin_sendsite.cpp @@ -72,7 +72,7 @@ namespace rubinius { /* nil means that the actual method object is 'up' from here */ if(vis && vis->method->nil_p()) goto keep_looking; - msg.method = as(entry); + msg.method = as(vis ? vis->method : entry); msg.module = module; break; } else if(vis) { @@ -95,7 +95,7 @@ namespace rubinius { goto keep_looking; } - msg.method = as(entry); + msg.method = as(vis->method); msg.module = module; break; } else {