From 0279dd536dd65b11b670dae95a6b08fab54825d4 Mon Sep 17 00:00:00 2001 From: Jess Balint Date: Thu, 11 Jun 2015 14:07:24 -0500 Subject: [PATCH] fix for setting breakpoints with jmethod_id objects --- debuglib.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/debuglib.lua b/debuglib.lua index a2d291f..c48fe9d 100644 --- a/debuglib.lua +++ b/debuglib.lua @@ -233,10 +233,10 @@ function bp(method, line_num) if not b.method_id then error("Cannot find method to set breakpoint") end - elseif type(method) == "userdata" then + elseif type(method) == "table" and method.classname == "jmethod_id" then b.method_id = method else - error("Invalid method, must be method declaration of form \"pkg/Class.name()V\" or a method_id object") + error("Invalid method, must be method declaration of form \"pkg/Class.name()V\" or a jmethod_id object") end b.location = method_location_for_line_num(b.method_id, b.line_num)