[swift-evolution] Renaming "Build Configuration"

Jordan Rose jordan_rose at apple.com
Fri Feb 12 16:05:35 CST 2016


> 
> On Jan 28, 2016, at 11:08, Kevin Ballard via swift-evolution <swift-evolution at swift.org> wrote:
> 
> Renaming this seems like a good idea.
>  
> On Wed, Jan 27, 2016, at 05:18 PM, Jordan Rose via swift-evolution wrote:
>> - "Custom Compilation Features" for all the user-defined options.
>> - "marks a custom compilation feature as present" as the --help text for -D.
>>  
>> …but I'd be happy if someone comes up with something better. (And I'd like feedback on if any of these names are problematic in some other way.)
>  
> How about "Conditional Compilation Flags" for the user-defined options? The term "flag" implies boolean, and also connotes the presence of the flag as being the true value. The help text can then say "marks a conditional compilation flag as true". The boolean nature of the flag also makes the syntax `#if SomeFlag` make more sense, because we're used to if conditions being boolean values.
>  

Closing the loop: I implemented this in https://github.com/apple/swift/commit/c90511a74e94a06f1199ecd3f8d004cbfa70410d, taking Kevin's suggestion of "flags" for the user-set options. Jack L from Apple convinced me to avoid the word "feature" as well, since the platform conditions refer to mutually exclusive environments ("os(OSX)" vs. "os(iOS)"), while "features" can usually be mixed.

Jordan



More information about the swift-evolution mailing list