[swift-evolution] Proposal: Make it easier to use unicode identifiers in Swift.
Félix Cloutier
felixcca at yahoo.ca
Fri Jan 15 17:48:43 CST 2016
It's to support the ones that are not too hard to type. É is a single key on my keyboard.
Félix
> Le 15 janv. 2016 à 18:39:14, Amir Michail via swift-evolution <swift-evolution at swift.org> a écrit :
>
>
>> On Jan 15, 2016, at 6:37 PM, Jordan Rose <jordan_rose at apple.com> wrote:
>>
>> Hi, Amir. What benefit does this feature have for a Swift programmer? In my mind, it makes it harder to reason about what something does, because there may now be multiple names for the same variable.
>>
>> Jordan
>
> What’s the point of supporting unicode characters in identifiers if almost all of them are too hard to type?
>
> With this approach, you can use standard text to type them and have them converted to unicode every once in a while (e.g., on a commit).
>
>>
>>> On Jan 14, 2016, at 15:34, Amir Michail via swift-evolution <swift-evolution at swift.org> wrote:
>>>
>>> In particular, allow the programmer to use text instead of unicode when convenient.
>>>
>>> For example:
>>>
>>> unicodealias alpha = α
>>>
>>> let alpha = 5.0
>>>
>>> print("α=\(α)”)
>>>
>>> Every once in a while, the programmer could request that the IDE/editor transform the text names to their unicode counterparts as determined by unicode aliases throughout the source.
>>>
>>>
>>>
>>> _______________________________________________
>>> swift-evolution mailing list
>>> swift-evolution at swift.org
>>> https://lists.swift.org/mailman/listinfo/swift-evolution
>>
>
> _______________________________________________
> swift-evolution mailing list
> swift-evolution at swift.org
> https://lists.swift.org/mailman/listinfo/swift-evolution
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-evolution/attachments/20160115/461d301b/attachment.html>
More information about the swift-evolution
mailing list