Skip to content

Commit ecf3c64

Browse files
committed
Fix breakpoint into a nested function
1 parent c95a13a commit ecf3c64

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

trepan/processor/location.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,9 @@ def resolve_location(proc, location) -> Optional[Location]:
174174
offset = lineinfo[0].offsets[0]
175175
mod_func_name = lineinfo[0].name
176176
if mod_func.co_name != mod_func_name:
177-
print("FIXME: resolve_location needs update to pick out function")
177+
# Breakpoint is in a nested function/method.
178+
# Get new code object
179+
mod_func = code_info.get(mod_func_name, mod_func)
178180
pass
179181
else:
180182
return INVALID_LOCATION

0 commit comments

Comments
 (0)