File tree Expand file tree Collapse file tree 2 files changed +1
-6
lines changed Expand file tree Collapse file tree 2 files changed +1
-6
lines changed Original file line number Diff line number Diff line change @@ -582,7 +582,6 @@ class SourceFile final : public FileUnit {
582582 bool hasDelayedBodyParsing () const ;
583583
584584 syntax::SourceFileSyntax getSyntaxRoot () const ;
585- bool hasSyntaxRoot () const ;
586585
587586 OpaqueTypeDecl *lookupOpaqueResultType (StringRef MangledName) override ;
588587
Original file line number Diff line number Diff line change @@ -1088,12 +1088,8 @@ void SourceFile::getInterfaceHash(llvm::SmallString<32> &str) const {
10881088 llvm::MD5::stringifyResult (result, str);
10891089}
10901090
1091- bool SourceFile::hasSyntaxRoot () const {
1092- return ParsingOpts.contains (ParsingFlags::BuildSyntaxTree);
1093- }
1094-
10951091syntax::SourceFileSyntax SourceFile::getSyntaxRoot () const {
1096- assert (hasSyntaxRoot () && " has no syntax root " );
1092+ assert (shouldBuildSyntaxTree () && " Syntax tree disabled " );
10971093 auto &eval = getASTContext ().evaluator ;
10981094 auto *mutableThis = const_cast <SourceFile *>(this );
10991095 return *evaluateOrDefault (eval, ParseSourceFileRequest{mutableThis}, {})
You can’t perform that action at this time.
0 commit comments