SIGN IN SIGN UP

bpo-29469: peephole: Remove const_stack (GH-4879)

Constant folding was moved to AST optimizer.
But compiler may emit LOAD_CONSTs + BUILD_TUPLE.
For example, default arguments can be constant tuple
if all arguments are constant.

This commit makes peephole's tuple folding simple.
It doesn't support nested tuples because nested
tuples are folded by AST optimizer already.
I
INADA Naoki committed
87010e85cb37192d63b1a30e5fabba307ad5a3f5
Parent: 902ab80
Committed by GitHub <noreply@github.com> on 12/18/2017, 6:52:54 AM