[swift-evolution] [Pitch] Clarify behavior of comments near operators

Jordan Rose jordan_rose at apple.com
Tue Dec 22 12:39:07 CST 2015

> On Dec 21, 2015, at 19:23, Jesse Rusak <me at jesserusak.com> wrote:
>> On Dec 21, 2015, at 3:18 PM, Jordan Rose <jordan_rose at apple.com <mailto:jordan_rose at apple.com>> wrote:
>> After looking at all your examples, I think I prefer "comments are not there" with a possible "multi-line comments are treated like newlines" extension. But either way I think having an actual model here and sticking to it is an improvement!
> Thanks for your thoughts! To be clear, are you suggesting “comments are not there” for the purposes of whitespace near operators, or as part of a more-general rule to be applied everywhere? (i.e. do you mean the first or second of the alternatives I listed?)

I'm not sure how your two alternatives map to these options, but I think the model I like has


as a postfix '!'. I'm not sure if I want to count

*/+ bar

as an infix '+', as an error, or as a de-facto line continuation mechanism (making a postfix '+'). I do agree it's important to pick something.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20151222/509ab0c6/attachment.html>

More information about the swift-evolution mailing list