Skip to content

Commit e6ed28f

Browse files
authored
Merge pull request #8694 from bluetech/rec-eval-wrapper
code: remove unneeded comparison eval wrapper
2 parents c198a7a + c90fdc6 commit e6ed28f

File tree

1 file changed

+1
-10
lines changed

1 file changed

+1
-10
lines changed

src/_pytest/_code/code.py

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -422,21 +422,12 @@ def recursionindex(self) -> Optional[int]:
422422
f = entry.frame
423423
loc = f.f_locals
424424
for otherloc in values:
425-
if f.eval(
426-
co_equal,
427-
__recursioncache_locals_1=loc,
428-
__recursioncache_locals_2=otherloc,
429-
):
425+
if otherloc == loc:
430426
return i
431427
values.append(entry.frame.f_locals)
432428
return None
433429

434430

435-
co_equal = compile(
436-
"__recursioncache_locals_1 == __recursioncache_locals_2", "?", "eval"
437-
)
438-
439-
440431
E = TypeVar("E", bound=BaseException, covariant=True)
441432

442433

0 commit comments

Comments
 (0)