#1214 Cascade as argument is compiled incorrectly

Closed
opened 8 years ago by nero · 0 comments

Originally at 2015-12-20T21:20:44Z by Herbert Vojčík closed at 2015-12-20T23:00:52Z

This code:

foo | x |
x := 1.
^ Array with: x with: ([x:=2] value; in: [x])

should produce #(1 2) but produces #(2 2) because [x:=2] value is compiled before Array with:with:.

Similarly with {x. [x:=2] value; in: [x]}.

Originally at 2015-12-20T21:20:44Z by Herbert Vojčík closed at 2015-12-20T23:00:52Z This code: ``` smalltalk foo | x | x := 1. ^ Array with: x with: ([x:=2] value; in: [x]) ``` should produce `#(1 2)` but produces `#(2 2)` because `[x:=2] value` is compiled before `Array with:with:`. Similarly with `{x. [x:=2] value; in: [x]}`.
Sign in to join this conversation.
No Label
No Milestone
No assignee
1 Participants
Loading...
Cancel
Save
There is no content yet.