swift
bacdb76e - [Playgrounds] Add new `swift-frontend` flag to control the set of Playground code transforms to apply.

Commit
2 years ago
[Playgrounds] Add new `swift-frontend` flag to control the set of Playground code transforms to apply. Generalize the "playground transform high performance" flag into a set of transform options that control each aspect of the code instrumentation. Instead of a single flag, we represent the playground transform options as a set of identifiers, with a new `-playground-option` flag to individually enable options. We don't yet support a "no-" prefix, but could do so if needed. For compatibility, the existing `-playground-high-performance` flag causes the same set of transforms to be disabled as before. We should consider whether to do something more elaborate here, similar to `Features.def`, where there is a clear definition in a single place of each kind of transform that can be controlled. That could be part of this change or a follow-on. Note that this is intended to control the types of user-visible results that are wanted — other flags, such as whether or not to use the extended form of the callbacks, remain as experimental features, since those deal with the mechanics and not the desired outcome. This is a WIP and still needs unit tests before being ready for review. rdar://109911673
Author
Committer
Parents
Loading