I would prefer for $ being available as operator symbol, so -1 to the proposal.
-Thorsten
> Am 22.10.2016 um 09:22 schrieb Will Stanton via swift-evolution
> :
>
> On $ specifically, I found this Wikipedia article listing native operators
> from other languages:
> https://en.wikipedia.org/wik
On $ specifically, I found this Wikipedia article listing native operators from
other languages: https://en.wikipedia.org/wiki/Operator_(computer_programming).
Haskell was listed with $ as an operator (‘Anything appearing after it will
take precedence over anything that comes before’ per
http://
Now for a position:
-1 on this proposal, because '$' should be legal in *any* identifier
position.
+1 for the proposal that '$' should be legal in *any* position.
___
swift-evolution mailing list
swift-evolution@swift.org
https://lists.swift.org/mailman
Several people here have called out implicit closure parameters as a
concern, which is actually irrelevant to adopting '$' in parameters.
It is perfectly feasible to accept '$' in parameters *generally*, and
reject identifiers of the form
$ followed by one or more decimal digits
in defining occ
On Wed, Oct 19, 2016 at 1:02 PM, Kevin Ballard via swift-evolution <
swift-evolution@swift.org> wrote:
> I'm actually vaguely surprised that the other currency symbols are
> considered valid identifiers, since they're not alphanumeric symbols. As
> for turning them into operators, it's a cute idea
On Tue, Oct 18, 2016 at 7:20 AM, Jay Abbott via swift-evolution <
swift-evolution@swift.org> wrote:
> It's s symbol. Here are some others:
> ! & * ( . -
>
> You wouldn't want to allow an identifier to start with any of those
> symbols, for obvious reasons.
>
That's an assertion. Can you substanti
On Fri, Oct 14, 2016 at 9:29 PM, Will Stanton via swift-evolution <
swift-evolution@swift.org> wrote:
> I’m a bit curious about how `$` is/would be used as a prefix operator!
> Perhaps I’m not creative :-(
>
Well for one thing, $(0) can be understood as a value constructor for a
currency object h
On Fri, Oct 14, 2016 at 1:53 PM, Hooman Mehr via swift-evolution <
swift-evolution@swift.org> wrote:
> I don’t think $ will be become available to be used as an operator if we
> remove its identifier use.
>
I'm about to put out a revised proposal for operators and symbol
identifiers that addresse
> On Oct 20, 2016, at 2:52 AM, Benjamin Spratling via swift-evolution
> wrote:
>
> struct Note {
> /// half-steps from middle-C, nil means the note is a rest
> var pitch:Int?
> //more properties
> init?(xmlNode: XMLNode) {
> if let pitchString:String = xmlNo
Howdy,
It seems the main question in discussing this proposal is “If $0, $1,
$2, $3 are automatic closure parameters, then what is “$”?”. Another thing
that has also recently come to my attention that Swift does not have a “result
of previous expression” magic identifier as some functio
Sent from my iPhone
> On 20 Oct 2016, at 07:54, Russ Bishop via swift-evolution
> wrote:
>
>
>> On Oct 17, 2016, at 11:45 PM, Rien via swift-evolution
>> wrote:
>>
>> “culturally offensive” is not a logical argument.
>> A programming language should be logically consistent no matter how m
> On Oct 17, 2016, at 11:45 PM, Rien via swift-evolution
> wrote:
>
> “culturally offensive” is not a logical argument.
> A programming language should be logically consistent no matter how many
> cultures are offended by it.
> If Swift is driven by SJW’s then very quickly it will cease to be
> On Oct 18, 2016, at 09:39 , Nevin Brackett-Rozinsky via swift-evolution
> wrote:
>
> It seems natural to me that currency symbols should be operators. This would
> allow, for example, prefix and postfix operators that take a number and
> return a “Currency” instance:
>
> let inMyPocket = $
> On Oct 18, 2016, at 11:39 AM, Nevin Brackett-Rozinsky via swift-evolution
> wrote:
>
> It seems natural to me that currency symbols should be operators. This would
> allow, for example, prefix and postfix operators that take a number and
> return a “Currency” instance:
>
> let inMyPocket =
I'm actually vaguely surprised that the other currency symbols are
considered valid identifiers, since they're not alphanumeric symbols.
As for turning them into operators, it's a cute idea, but it doesn't
work for any symbol that's used by multiple countries. For example,
would $3.50 be USD, AUD,
On Mon, Oct 17, 2016, at 11:25 PM, Jean-Denis Muys via swift-evolution wrote:
> Now for the elephant in the room: '$' is a currency symbol. As such it
> should be handled like any other currency symbol. Thinking otherwise
> would be very culturally offensive.
>
> So can I use € as an variable name
It seems natural to me that currency symbols should be operators. This
would allow, for example, prefix and postfix operators that take a number
and return a “Currency” instance:
let inMyPocket = $20
let lochNess = £3.50
let twoBits = 25¢
if (inMyPocket - lochNess) > twoBits { … }
Of course, the
On Fri, Oct 14, 2016 at 1:00 PM Chris Lattner via swift-evolution <
swift-evolution@swift.org> wrote:
> Hello Swift community,
>
> The review of "SE-0144: Allow Single Dollar Sign as a Valid Identifier"
> begins now and runs through October 18. The proposal is available here:
>
>
> https://github.
on Mon Oct 17 2016, Jean-Denis Muys wrote:
> While I already tersely supported this proposal, following all the negative
> reactions, I feel compelled to revisit my position. The main reason is that
> it strikes me that most points of view so far, including mine, were really
> culturally short s
* What is your evaluation of the proposal?
+1
We should do the best to avoid source breaking change in Swift4.
https://github.com/ankurp/Dollar is used in so many projects.
I believe removing this might discourage them from using Swift.
* Is the problem being addressed significant
>
> Now for the elephant in the room: '$' is a currency symbol. As such it
> should be handled like any other currency symbol. Thinking otherwise would
> be very culturally offensive.
>
The fact that it's a currency symbol is totally irrelevant.
It's s symbol. Here are some others:
! & * ( . -
Yo
I'd prefer to replace $ with # in closure parameters, plus make $ equal in
rights to other currency symbols.
In C and JS, dollar sign is actually equal in rights to other currency symbols.
Swift is closer to them than to Perl, Shell, PHP, so it makes sense to
follow them here.
_
“culturally offensive” is not a logical argument.
A programming language should be logically consistent no matter how many
cultures are offended by it.
If Swift is driven by SJW’s then very quickly it will cease to be an effective
language.
Having said that, I cannot think of a logical reason no
While I already tersely supported this proposal, following all the negative
reactions, I feel compelled to revisit my position. The main reason is that
it strikes me that most points of view so far, including mine, were really
culturally short sighted, and far too much US-centric.
I totally agree
> * What is your evaluation of the proposal?
I am against it.
> * Is the problem being addressed significant enough to warrant a change
to Swift?
No - if this change were made it would be a regression. The rationale for
removing it in the first place was and remains valid.
> * Does this proposa
Proposal link:
https://github.com/apple/swift-evolution/blob/master/propo
sals/0144-allow-single-dollar-sign-as-valid-identifier.md
> * What is your evaluation of the proposal?
>
-1.
The proposal does not actually provide motivation for keeping $ beyond "the
Dollar library alre
> On Oct 14, 2016, at 12:59 PM, Chris Lattner via swift-evolution
> wrote:
>
> Hello Swift community,
>
> The review of "SE-0144: Allow Single Dollar Sign as a Valid Identifier"
> begins now and runs through October 18. The proposal is available here:
>
>
> https://github.com/apple/sw
> * What is your evaluation of the proposal?
-1. I would much rather see it either as an operator, or more likely as some
other special syntax/meaning in Swift.
> * Is the problem being addressed significant enough to warrant a change
> to Swift?
No. Providing backwards compatibilit
> * What is your evaluation of the proposal?
-1
The only use case of ‘$’ would be in short funny swift examples or in a
playground, e.g. as a variable for a monetary amount. Similar to the emojis
used as variables in the wild.
But then, you could just use the $emoji…
> * Is the problem being
> On 14 Oct 2016, at 20:59, Chris Lattner via swift-evolution
> wrote:
>
> * What is your evaluation of the proposal?
Not in favour, sorry. While I've used this kind of pattern in Javascript I just
don't see what it really adds compared to a more explicit name. As a general
rule I pref
I’m a bit curious about how `$` is/would be used as a prefix operator! Perhaps
I’m not creative :-(
Regards,
Will Stanton
> On Oct 14, 2016, at 6:42 PM, Alex Martini via swift-evolution
> wrote:
>
>> On Oct 14, 2016, at 1:53 PM, Hooman Mehr via swift-evolution
>> wrote:
>>
>>> On Oct 14, 2
> On Oct 14, 2016, at 12:59 PM, Chris Lattner via swift-evolution
> wrote:
>
> Hello Swift community,
>
> The review of "SE-0144: Allow Single Dollar Sign as a Valid Identifier"
> begins now and runs through October 18. The proposal is available here:
>
>
> https://github.com/apple/swif
* What is your evaluation of the proposal?
-1
* Does this proposal fit well with the feel and direction of Swift?
Not at all.
* How much effort did you put into your review? A glance, a quick reading, or
an in-depth study?
Not much, as it just does not appeal to me.
> On Oct 14, 2016, at 2:59 PM, Chris Lattner via swift-evolution
> wrote:
>
> Hello Swift community,
>
> The review of "SE-0144: Allow Single Dollar Sign as a Valid Identifier"
> begins now and runs through October 18. The proposal is available here:
>
>
> https://github.com/apple/swif
> On Oct 14, 2016, at 3:42 PM, Alex Martini via swift-evolution
> wrote:
>
>> On Oct 14, 2016, at 1:53 PM, Hooman Mehr via swift-evolution
>> mailto:swift-evolution@swift.org>> wrote:
>>
>>> On Oct 14, 2016, at 1:49 PM, Daniel Duan via swift-evolution
>>> mailto:swift-evolution@swift.org>> w
> * What is your evaluation of the proposal?
-1. If it were a valid identifier, $ would look even more confusing when used
as a type name. I’d rather see $ used as an operator.
> * Is the problem being addressed significant enough to warrant a change to
> Swift?
> * Does this proposal fit well
> On Oct 14, 2016, at 1:53 PM, Hooman Mehr via swift-evolution
> wrote:
>
>> On Oct 14, 2016, at 1:49 PM, Daniel Duan via swift-evolution
>> mailto:swift-evolution@swift.org>> wrote:
>>
>> Agree with Robert here. I'd rather be able to use it as part of operators.
>> Currently the character se
> * What is your evaluation of the proposal?
-1. I don’t like the idea of a user-defined `$` identifier. I agree with the
reasons for removing it. If it is allowed as a user-defined entity it feels an
operator is more appropriate. Otherwise, it could be reserved as a special,
compile
I don’t think $ will be become available to be used as an operator if we remove
its identifier use.
> On Oct 14, 2016, at 1:49 PM, Daniel Duan via swift-evolution
> wrote:
>
> Agree with Robert here. I'd rather be able to use it as part of operators.
> Currently the character set for operato
Agree with Robert here. I'd rather be able to use it as part of operators.
Currently the character set for operators and identifier head are mutually
exclusive. So this proposal will remove that possibility. This deserves some
discussion.
Daniel Duan
Sent from my iPhone
> On Oct 14, 2016, at 1
-1
I agree with the motivations to remove it.
On Fri, Oct 14, 2016, at 12:59, Chris Lattner via swift-evolution wrote:
> Hello Swift community,
>
> The review of "SE-0144: Allow Single Dollar Sign as a Valid
> Identifier"
> begins now and runs through October 18. The proposal is
> available here
As the author of the patch that introduced this and the patch that will come
out of this discussion, I have no problems one way or the other. Just bear in
mind that if $ is an identifier head character then it cannot be used in
operators - something I have a library with a vested interest in.
Hello Swift community,
The review of "SE-0144: Allow Single Dollar Sign as a Valid Identifier" begins
now and runs through October 18. The proposal is available here:
https://github.com/apple/swift-evolution/blob/master/proposals/0144-allow-single-dollar-sign-as-valid-identifier.md
Rev
43 matches
Mail list logo