Re: [go-nuts] Possible language improvement re multiple assignment

2020-12-28 Thread Ian Lance Taylor
On Mon, Dec 28, 2020 at 11:40 AM bobj...@gmail.com wrote: > > For the case of multiple variable assignment where some of the target > variables are to be created in the local scope and some are to be found in > the existing scope... > > Allow: > > existingVar, :newVar = 1, 2 > > instead of: >

Re: [go-nuts] Possible language improvement re multiple assignment

2020-12-28 Thread Artur Vianna
The only "disadvantage" i could think would be increasing the ways one could create variables: var i int i := 0 :i = 0 and it allows this madness: :a, b, :c, d, :e = 0, 1, 2, 3, 4 Otherwise i like the idea, but i don't mind using the long version in pro of simplicity. On Mon, 28 Dec 2020, 16:40

[go-nuts] Possible language improvement re multiple assignment

2020-12-28 Thread bobj...@gmail.com
For the case of multiple variable assignment where some of the target variables are to be created in the local scope and some are to be found in the existing scope... Allow: existingVar, :newVar = 1, 2 instead of: var newVar int existingVar, newVar = 1, 2 That additional line for expli