Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-05 Thread Dany St-Amant via swift-evolution
Yet another inconsistency in this area (for people who care about them) While the 'while {}' does not support trailing closures, the 'repeat {} while' does support them. So, will the folks against supporting them in 'guard' ask for a change to drop the support in the 'repeat {} while'? Dany >

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-05 Thread James Richard via swift-evolution
+1. I feel this fits well with Swift, and the current inconsistency with other statements warrants the change. > On Mar 31, 2016, at 8:27 PM, Douglas Gregor via swift-evolution > wrote: > > Hello Swift community, > > The review of SE-0056 "Allow trailing closures in `guard` conditions" begins

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-05 Thread Jeremy Pereira via swift-evolution
> On 4 Apr 2016, at 18:18, Haravikk wrote: > >> >> On 4 Apr 2016, at 15:49, Jeremy Pereira >> wrote: >> >>> On 3 Apr 2016, at 17:20, Haravikk via swift-evolution >>> wrote: >>> >>> Although I use trailing closures a lot less now, I think I’m a +1 anyway >>> for consistency’s sake. >>> >

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-05 Thread Radosław Pietruszewski via swift-evolution
> What is your evaluation of the proposal? +1. I like the rule of “don’t make me think”. If I write a piece of code that seems correct to me, why would the compiler “intentionally” stop me from accepting it? Just smooth out this rough edge and remove one scenario in which a compiler error stops

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-04 Thread Russ Bishop via swift-evolution
> On Mar 31, 2016, at 8:27 PM, Douglas Gregor via swift-evolution > wrote: > > Hello Swift community, > > The review of SE-0056 "Allow trailing closures in `guard` conditions" begins > now and runs through April 5, 2016. The proposal is available here: > > https://github.com/apple/swift-evol

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-04 Thread Thorsten Seitz via swift-evolution
> Am 05.04.2016 um 01:52 schrieb Dany St-Amant via swift-evolution > :. > > I am with you here, Swift is Swift, C is C, Swift should not be hampered by > keeping the syntax identical to C. But, it seems that most prefer to type > less, so we should be really careful with proposing new keywords

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-04 Thread Dany St-Amant via swift-evolution
> Le 4 avr. 2016 à 10:19, Patrick Gili a écrit : > > If I understand you correctly, you think adding keywords represents an > inconsistency. I didn't write that, maybe I should have put my reply between your two paragraphs. Adding keywords such as 'then' and 'do' could add some consistency,

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-04 Thread Xiaodi Wu via swift-evolution
On Mon, Apr 4, 2016 at 11:18 AM, Haravikk via swift-evolution wrote: > >> On 4 Apr 2016, at 15:49, Jeremy Pereira >> wrote: >> >>> On 3 Apr 2016, at 17:20, Haravikk via swift-evolution >>> wrote: >>> >>> Although I use trailing closures a lot less now, I think I’m a +1 anyway >>> for consiste

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-04 Thread Haravikk via swift-evolution
> On 4 Apr 2016, at 15:49, Jeremy Pereira > wrote: > >> On 3 Apr 2016, at 17:20, Haravikk via swift-evolution >> wrote: >> >> Although I use trailing closures a lot less now, I think I’m a +1 anyway for >> consistency’s sake. >> >> I actually really like the idea of having trailing keyword

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-04 Thread Thorsten Seitz via swift-evolution
> Am 04.04.2016 um 16:49 schrieb Jeremy Pereira via swift-evolution > : > > >> On 3 Apr 2016, at 17:20, Haravikk via swift-evolution >> wrote: >> >> Although I use trailing closures a lot less now, I think I’m a +1 anyway for >> consistency’s sake. >> >> I actually really like the idea of

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-04 Thread Jeremy Pereira via swift-evolution
> On 3 Apr 2016, at 17:20, Haravikk via swift-evolution > wrote: > > Although I use trailing closures a lot less now, I think I’m a +1 anyway for > consistency’s sake. > > I actually really like the idea of having trailing keywords in loops and if > statements, these needn’t be required (exc

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-04 Thread Patrick Gili via swift-evolution
If I understand you correctly, you think adding keywords represents an inconsistency. However, I think it would add considerable consistency and utility to the Swift language. Yes, it would make it inconsistent with the generations of C-like languages that have come before it. However, I think

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-03 Thread Xiaodi Wu via swift-evolution
One idea related to this `for...do` syntax--maybe this will satisfy some objections listed in the proposal: Currently, Swift has optional semicolons. In the same spirit, suppose control statements have optional colons, like this: `for eachValue in theValues: { code }`. All current syntax continues

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-03 Thread Rudolf Adamkovic via swift-evolution
Like others, I'm -1 on this due to added inconsistency between the guard and other control flow statements. R+ Sent from my iPhone > On 01 Apr 2016, at 05:27, Douglas Gregor via swift-evolution > wrote: > > Hello Swift community, > > The review of SE-0056 "Allow trailing closures in `guard`

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-03 Thread Dany St-Amant via swift-evolution
> Le 2 avr. 2016 à 15:39, Patrick Gili via swift-evolution > a écrit : > >> What is your evaluation of the proposal? > I think there is a lot of value to allowing trailing closures in the guard > condition clause. However, not at the cost of inconsistency. We have reviewed > many proposals ov

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-03 Thread Haravikk via swift-evolution
Although I use trailing closures a lot less now, I think I’m a +1 anyway for consistency’s sake. I actually really like the idea of having trailing keywords in loops and if statements, these needn’t be required (except where a trailing closure is used) but for example it means I could do a full

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-03 Thread Howard Lovatt via swift-evolution
Interesting idea to put keywords in the other statements so that they can also use trailing closures! On Sunday, 3 April 2016, Ilya Belenkiy via swift-evolution < swift-evolution@swift.org> wrote: > >- What is your evaluation of the proposal? > > +1. I stumble on this quite often. > > >-

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-02 Thread Ilya Belenkiy via swift-evolution
> What is your evaluation of the proposal? +1. I stumble on this quite often. > Is the problem being addressed significant enough to warrant a change to > Swift? yes > Does this proposal fit well with the feel and direction of Swift? yes > How much effort did you put into your review? A glance,

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-02 Thread Patrick Gili via swift-evolution
> What is your evaluation of the proposal? I think there is a lot of value to allowing trailing closures in the guard condition clause. However, not at the cost of inconsistency. We have reviewed many proposals over the last month that addressed consistency issues in the Swift language, and if I

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-01 Thread Shawn Erickson via swift-evolution
On Thu, Mar 31, 2016 at 8:27 PM Douglas Gregor via swift-evolution < swift-evolution@swift.org> wrote: > Hello Swift community, > > The review of SE-0056 "Allow trailing closures in `guard` conditions" > begins now and runs through April 5, 2016. The proposal is available here: > > > https://githu

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-01 Thread Howard Lovatt via swift-evolution
+1 with the same evaluation as Sebastian Hagedorn On Friday, 1 April 2016, Sebastian Hagedorn via swift-evolution < swift-evolution@swift.org> wrote: > >- What is your evaluation of the proposal? > > +1 > > >- Is the problem being addressed significant enough to warrant a >change to S

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-01 Thread Rob Mayoff via swift-evolution
I would prefer the conditional statements to treat trailing closures consistently, rather than allow this minor but inconsistent convenience. I don't think this needs changing. I read the proposal and followed the list discussion. ___ swift-evolution mail

Re: [swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-01 Thread David Hart via swift-evolution
> What is your evaluation of the proposal? -1 I admire the goal of making trailing closures usably in guard, but I do not like the inconsistency between guard and if. I also never liked the inconsistency with the else keyword in guard. Bother those reasons means that I’m worried that this will i

[swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-04-01 Thread Pelaia II, Tom via swift-evolution
+1 for this proposal. The resulting code would be clear enough and brings benefit. ___ swift-evolution mailing list swift-evolution@swift.org https://lists.swift.org/mailman/listinfo/swift-evolution

[swift-evolution] [Review] SE-0056: Allow trailing closures in `guard` conditions

2016-03-31 Thread Douglas Gregor via swift-evolution
Hello Swift community, The review of SE-0056 "Allow trailing closures in `guard` conditions" begins now and runs through April 5, 2016. The proposal is available here: https://github.com/apple/swift-evolution/blob/master/proposals/0056-trailing-closures-in-guard.md Reviews are an important part