x/tools/go/ssa: bad order of evaluation with slice expressions #52142
Labels
FrozenDueToAge
NeedsFix
The path to resolution is known, but the work has not been done.
Tools
This label describes issues relating to any tools in the x/tools repository.
Milestone
This function:
should invoke
f()
beforeg()
, because it's lexically to the left. But when compiled with x/tools/go/ssa, it gives the opposite order:https://go.dev/play/p/aY22d2R-3Zw
I think this is simply because the ast.SliceExpr case in builder.expr visits e.High before e.Low.
/cc @timothy-king @zpavlinovic @findleyr
The text was updated successfully, but these errors were encountered: