|
55 | 55 | #endif |
56 | 56 |
|
57 | 57 | #ifndef EXPERIMENTAL_FEATURE |
58 | | -# define EXPERIMENTAL_FEATURE(FeatureName) \ |
| 58 | +// Warning: setting `AvailableInProd` to `true` on a feature means that the flag |
| 59 | +// cannot be dropped in the future. |
| 60 | +# define EXPERIMENTAL_FEATURE(FeatureName, AvailableInProd) \ |
59 | 61 | LANGUAGE_FEATURE(FeatureName, 0, #FeatureName, \ |
60 | 62 | langOpts.hasFeature(#FeatureName)) |
61 | 63 | #endif |
@@ -94,63 +96,63 @@ UPCOMING_FEATURE(ForwardTrailingClosures, 286, 6) |
94 | 96 | UPCOMING_FEATURE(BareSlashRegexLiterals, 354, 6) |
95 | 97 | UPCOMING_FEATURE(ExistentialAny, 335, 6) |
96 | 98 |
|
97 | | -EXPERIMENTAL_FEATURE(StaticAssert) |
98 | | -EXPERIMENTAL_FEATURE(VariadicGenerics) |
99 | | -EXPERIMENTAL_FEATURE(NamedOpaqueTypes) |
100 | | -EXPERIMENTAL_FEATURE(FlowSensitiveConcurrencyCaptures) |
101 | | -EXPERIMENTAL_FEATURE(MoveOnly) |
102 | | -EXPERIMENTAL_FEATURE(OneWayClosureParameters) |
103 | | -EXPERIMENTAL_FEATURE(TypeWitnessSystemInference) |
104 | | -EXPERIMENTAL_FEATURE(ResultBuilderASTTransform) |
105 | | -EXPERIMENTAL_FEATURE(LayoutPrespecialization) |
| 99 | +EXPERIMENTAL_FEATURE(StaticAssert, false) |
| 100 | +EXPERIMENTAL_FEATURE(VariadicGenerics, false) |
| 101 | +EXPERIMENTAL_FEATURE(NamedOpaqueTypes, false) |
| 102 | +EXPERIMENTAL_FEATURE(FlowSensitiveConcurrencyCaptures, false) |
| 103 | +EXPERIMENTAL_FEATURE(MoveOnly, false) |
| 104 | +EXPERIMENTAL_FEATURE(OneWayClosureParameters, false) |
| 105 | +EXPERIMENTAL_FEATURE(TypeWitnessSystemInference, false) |
| 106 | +EXPERIMENTAL_FEATURE(ResultBuilderASTTransform, true) |
| 107 | +EXPERIMENTAL_FEATURE(LayoutPrespecialization, false) |
106 | 108 |
|
107 | 109 | /// Whether to enable experimental differentiable programming features: |
108 | 110 | /// `@differentiable` declaration attribute, etc. |
109 | | -EXPERIMENTAL_FEATURE(DifferentiableProgramming) |
| 111 | +EXPERIMENTAL_FEATURE(DifferentiableProgramming, false) |
110 | 112 |
|
111 | 113 | /// Whether to enable forward mode differentiation. |
112 | | -EXPERIMENTAL_FEATURE(ForwardModeDifferentiation) |
| 114 | +EXPERIMENTAL_FEATURE(ForwardModeDifferentiation, false) |
113 | 115 |
|
114 | 116 | /// Whether to enable experimental `AdditiveArithmetic` derived |
115 | 117 | /// conformances. |
116 | | -EXPERIMENTAL_FEATURE(AdditiveArithmeticDerivedConformances) |
| 118 | +EXPERIMENTAL_FEATURE(AdditiveArithmeticDerivedConformances, false) |
117 | 119 |
|
118 | 120 | /// Whether Objective-C completion handler parameters are imported as |
119 | 121 | /// @Sendable. |
120 | | -EXPERIMENTAL_FEATURE(SendableCompletionHandlers) |
| 122 | +EXPERIMENTAL_FEATURE(SendableCompletionHandlers, false) |
121 | 123 |
|
122 | 124 | /// Enables opaque type erasure without also enabling implict dynamic |
123 | | -EXPERIMENTAL_FEATURE(OpaqueTypeErasure) |
| 125 | +EXPERIMENTAL_FEATURE(OpaqueTypeErasure, false) |
124 | 126 |
|
125 | 127 | /// Whether to enable experimental @typeWrapper feature which allows to |
126 | 128 | /// declare a type that controls access to all stored properties of the |
127 | 129 | /// wrapped type. |
128 | | -EXPERIMENTAL_FEATURE(TypeWrappers) |
| 130 | +EXPERIMENTAL_FEATURE(TypeWrappers, false) |
129 | 131 |
|
130 | 132 | /// Whether to perform round-trip testing of the Swift Swift parser. |
131 | | -EXPERIMENTAL_FEATURE(ParserRoundTrip) |
| 133 | +EXPERIMENTAL_FEATURE(ParserRoundTrip, false) |
132 | 134 |
|
133 | 135 | /// Whether to perform validation of the parse tree produced by the Swift |
134 | 136 | /// Swift parser. |
135 | | -EXPERIMENTAL_FEATURE(ParserValidation) |
| 137 | +EXPERIMENTAL_FEATURE(ParserValidation, false) |
136 | 138 |
|
137 | 139 | /// Whether to fold sequence expressions in the syntax tree produced by the |
138 | 140 | /// Swift Swift parser. |
139 | | -EXPERIMENTAL_FEATURE(ParserSequenceFolding) |
| 141 | +EXPERIMENTAL_FEATURE(ParserSequenceFolding, false) |
140 | 142 |
|
141 | 143 | /// Enables implicit some while also enabling existential `any` |
142 | | -EXPERIMENTAL_FEATURE(ImplicitSome) |
| 144 | +EXPERIMENTAL_FEATURE(ImplicitSome, false) |
143 | 145 |
|
144 | 146 | /// Parse using the Swift (swift-syntax) parser and use ASTGen to generate the |
145 | 147 | /// corresponding syntax tree. |
146 | | -EXPERIMENTAL_FEATURE(ParserASTGen) |
| 148 | +EXPERIMENTAL_FEATURE(ParserASTGen, false) |
147 | 149 |
|
148 | 150 | /// Enable the experimental macros feature. |
149 | | -EXPERIMENTAL_FEATURE(Macros) |
| 151 | +EXPERIMENTAL_FEATURE(Macros, false) |
150 | 152 |
|
151 | 153 | /// Parse using the Swift (swift-syntax) parser and use ASTGen to generate the |
152 | 154 | /// corresponding syntax tree. |
153 | | -EXPERIMENTAL_FEATURE(BuiltinMacros) |
| 155 | +EXPERIMENTAL_FEATURE(BuiltinMacros, false) |
154 | 156 |
|
155 | 157 | #undef EXPERIMENTAL_FEATURE |
156 | 158 | #undef UPCOMING_FEATURE |
|
0 commit comments