[swift-evolution] [swift-evolution-announce] [Review] SE-0084: Allow trailing commas in parameter lists and tuples
Rainer Brockerhoff
rainer at brockerhoff.net
Thu May 12 08:22:24 CDT 2016
On 5/11/16 14:29, Ricardo Parada via swift-evolution wrote:
> Dropping the commas looks good and doesn't look like someone made a mistake. I don't know what other implications / complications dropping the commas would have but I like it.
>
>> On May 11, 2016, at 12:20 PM, Vladimir.S via swift-evolution <swift-evolution at swift.org> wrote:
>>
>> Personally I support the idea of dropping comma in array/dict to allow line break separate elements(like operations in Swift code):
>> let a = [
>> 10
>> 20
>> 30
>> 40
>> ]
>>
>> let d = [
>> 10 : "a"
>> 20 : "b"
>> 30 : "c"
>> 40 : "d"
>> ]
I'm +1 on allowing either trailing commas *or* a line-break instead of
where a comma is expected.
Just as we allow a line-break where a semicolon is expected in a list of
statements.
-1 on making trailing commas mandatory, just as I'm against making
semicolons mandatory again :-)
--
Rainer Brockerhoff <rainer at brockerhoff.net>
Belo Horizonte, Brazil
"In the affairs of others even fools are wise
In their own business even sages err."
http://brockerhoff.net/blog/
More information about the swift-evolution
mailing list