We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f97bfd5 commit cf70084Copy full SHA for cf70084
1 file changed
line_profiler/_line_profiler.pyx
@@ -504,12 +504,11 @@ cdef class LineProfiler:
504
construct something similar for backwards compatibility.
505
"""
506
c_last_time = self.c_last_time
507
- code_hash_map = self.code_hash_map
508
py_last_time = {}
509
- for code, code_hashes in code_hash_map.items():
510
- for code_hash in code_hashes:
511
- if code_hash in c_last_time:
512
- py_last_time[code] = c_last_time[code_hash]
+ for code in self.code_hash_map:
+ block_hash = hash(code.co_code)
+ if block_hash in c_last_time:
+ py_last_time[code] = c_last_time[block_hash]
513
return py_last_time
514
515
0 commit comments