[swift-users] true false vs yes no
David Sweeris
davesweeris at mac.com
Sun Feb 7 12:47:33 CST 2016
I'm mildly in favor of adding yes/no, but very much against removing true/false.
This should probably move to the swift-evolution list.
Sent from my iPhone
> On Feb 7, 2016, at 09:19, Isaac Gouy via swift-users <swift-users at swift.org> wrote:
>
> On Sunday, February 7, 2016 8:23 AM, Oliver M <selectedfordeletion at yahoo.com> wrote:
>
>
>> The term "isLightOn" due to it sounding like a question suggests it having variability
>
>> (being a variable): isLightOn = yes ; isLightOn = no ; both seem logically valid.
>
> In programming, the term does not stand alone; the term has a context provided by other code statements -- if, while ...
>
> if isLightOn { }
>
>
> while isLightOn { }
>
> Those seem like peculiar questions.
>
>
>> The term "lightIsOn" due to it sounding like an answer suggests it being non-variable (being a value, perhaps an enum) conditionOfLight = lightIsOn ; conditionOfLight = lightIsDimmed ;
>> conditionOfLight = lightIsOff; seem logically valid.
>
> When more than 2 states are needed, Yes/No True/False won't be enough.
> _______________________________________________
> swift-users mailing list
> swift-users at swift.org
> https://lists.swift.org/mailman/listinfo/swift-users
More information about the swift-users
mailing list