Feature or enhancement
Proposal:
I noticed that
produces these instructions:
3 RESUME 0
4 LOAD_FAST_BORROW 0 (x)
POP_TOP
LOAD_COMMON_CONSTANT 7 (None)
RETURN_VALUE
Full reproducer
from dis import dis
def f(x):
x
dis(f)
The compiler should get rid of any LOAD_FAST_BORROW; POP_TOP pairs.
I will work on this.
Has this already been discussed elsewhere?
This is a minor feature, which does not need previous discussion elsewhere
Links to previous discussion of this feature:
No response
Linked PRs
Feature or enhancement
Proposal:
I noticed that
produces these instructions:
Full reproducer
The compiler should get rid of any
LOAD_FAST_BORROW; POP_TOPpairs.I will work on this.
Has this already been discussed elsewhere?
This is a minor feature, which does not need previous discussion elsewhere
Links to previous discussion of this feature:
No response
Linked PRs
LOAD_FAST/LOAD_FAST_BORROW; POP_TOPpairs #152643