File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -865,6 +865,11 @@ static llvm::cl::list<std::string>
865
865
llvm::cl::desc (" Enable an experimental feature" ),
866
866
llvm::cl::cat(Category));
867
867
868
+ static llvm::cl::list<std::string>
869
+ EnableUpcomingFeatures (" enable-upcoming-feature" ,
870
+ llvm::cl::desc (" Enable a feature that will be introduced in an upcoming language version" ),
871
+ llvm::cl::cat(Category));
872
+
868
873
static llvm::cl::list<std::string>
869
874
AccessNotesPath (" access-notes-path" , llvm::cl::desc(" Path to access notes file" ),
870
875
llvm::cl::cat(Category));
@@ -4421,6 +4426,12 @@ int main(int argc, char *argv[]) {
4421
4426
}
4422
4427
}
4423
4428
4429
+ for (const auto &featureArg : options::EnableUpcomingFeatures) {
4430
+ if (auto feature = getUpcomingFeature (featureArg)) {
4431
+ InitInvok.getLangOptions ().Features .insert (*feature);
4432
+ }
4433
+ }
4434
+
4424
4435
if (!options::Triple.empty ())
4425
4436
InitInvok.setTargetTriple (options::Triple);
4426
4437
if (!options::SwiftVersion.empty ()) {
You can’t perform that action at this time.
0 commit comments