Merge pull request #15226 from Coeur/patch-1
Hi ho, Typo!
diff --git a/lib/AST/ASTDumper.cpp b/lib/AST/ASTDumper.cpp
index f493842..73bb21e 100644
--- a/lib/AST/ASTDumper.cpp
+++ b/lib/AST/ASTDumper.cpp
@@ -525,7 +525,7 @@
PrintWithColorRAII(OS, ParenthesisColor) << ')';
}
void visitOptionalSomePattern(OptionalSomePattern *P) {
- printCommon(P, "optional_some_element");
+ printCommon(P, "pattern_optional_some");
OS << '\n';
printRec(P->getSubPattern());
PrintWithColorRAII(OS, ParenthesisColor) << ')';
diff --git a/stdlib/public/Platform/MachError.swift b/stdlib/public/Platform/MachError.swift
index e7eedb3..9a30dc1 100644
--- a/stdlib/public/Platform/MachError.swift
+++ b/stdlib/public/Platform/MachError.swift
@@ -203,4 +203,4 @@
/// The requested property cannot be changed at this time.
case policyStatic = 51
}
-#endif // os(OSX) || os(iOS) || os(tvOS) || os(watchOS)
+#endif // os(macOS) || os(iOS) || os(tvOS) || os(watchOS)
diff --git a/tools/swift-syntax-test/swift-syntax-test.cpp b/tools/swift-syntax-test/swift-syntax-test.cpp
index 3f4e8b0..fccfc95 100644
--- a/tools/swift-syntax-test/swift-syntax-test.cpp
+++ b/tools/swift-syntax-test/swift-syntax-test.cpp
@@ -102,6 +102,12 @@
llvm::cl::init(false));
static llvm::cl::opt<bool>
+VerifySyntaxTree("verify-syntax-tree",
+ llvm::cl::desc("Emit warnings for unknown nodes"),
+ llvm::cl::cat(Category),
+ llvm::cl::init(true));
+
+static llvm::cl::opt<bool>
Visual("v",
llvm::cl::desc("Print visually"),
llvm::cl::cat(Category),
@@ -148,7 +154,7 @@
const char *MainExecutablePath) {
CompilerInvocation Invocation;
Invocation.getLangOptions().BuildSyntaxTree = true;
- Invocation.getLangOptions().VerifySyntaxTree = true;
+ Invocation.getLangOptions().VerifySyntaxTree = options::VerifySyntaxTree;
Invocation.getFrontendOptions().InputsAndOutputs.addInputFile(InputFileName);
Invocation.setMainExecutablePath(
llvm::sys::fs::getMainExecutable(MainExecutablePath,