File tree Expand file tree Collapse file tree 1 file changed +1
-7
lines changed Expand file tree Collapse file tree 1 file changed +1
-7
lines changed Original file line number Diff line number Diff line change @@ -188,11 +188,6 @@ static bool hasAccessors(AbstractStorageDecl *asd) {
188
188
llvm_unreachable (" Unhandled ContinuationKind in switch." );
189
189
}
190
190
191
- // / Determine whether this is a top-level code declaration.
192
- static bool isRealTopLevelCodeDecl (Decl *decl) {
193
- return isa<TopLevelCodeDecl>(decl);
194
- }
195
-
196
191
void ASTScope::expand () const {
197
192
assert (!isExpanded () && " Already expanded the children of this node" );
198
193
ASTContext &ctx = getASTContext ();
@@ -300,7 +295,7 @@ void ASTScope::expand() const {
300
295
301
296
// If the declaration is a top-level code declaration, turn the source
302
297
// file into a continuation. We're done.
303
- if (isRealTopLevelCodeDecl (decl)) {
298
+ if (isa<TopLevelCodeDecl> (decl)) {
304
299
addActiveContinuation (this );
305
300
break ;
306
301
}
@@ -937,7 +932,6 @@ ASTScope *ASTScope::createIfNeeded(const ASTScope *parent, Decl *decl) {
937
932
}
938
933
939
934
case DeclKind::TopLevelCode:
940
- if (!isRealTopLevelCodeDecl (decl)) return nullptr ;
941
935
return new (ctx) ASTScope (parent, cast<TopLevelCodeDecl>(decl));
942
936
943
937
case DeclKind::Protocol:
You can’t perform that action at this time.
0 commit comments