Skip to content

Commit 40cd518

Browse files
author
David Ungar
committed
Rm doISplitAScope for visitBraceStmt
1 parent 6f6a772 commit 40cd518

File tree

2 files changed

+2
-9
lines changed

2 files changed

+2
-9
lines changed

include/swift/AST/ASTScope.h

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -277,13 +277,6 @@ class ASTScopeImpl {
277277

278278

279279
#pragma mark - - creation queries
280-
protected:
281-
/// In other words, does this scope introduce a new definition
282-
bool doISplitAScope() const {
283-
// Before an abstract storage decl, the decl is inaccessible.
284-
// After an abstract storage decl, it is now accessible.
285-
return isThisAnAbstractStorageDecl();
286-
}
287280
public:
288281
virtual bool isThisAnAbstractStorageDecl() const { return false; }
289282

lib/AST/ASTScopeCreation.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -462,8 +462,8 @@ class ASTVisitorForScopeCreation
462462

463463
ASTScopeImpl *visitBraceStmt(BraceStmt *bs, ASTScopeImpl *p,
464464
ScopeCreator &scopeCreator) {
465-
auto *insertionPoint = scopeCreator.createSubtree<BraceStmtScope>(p, bs);
466-
return p->doISplitAScope() ? insertionPoint : p;
465+
scopeCreator.createSubtree<BraceStmtScope>(p, bs);
466+
return p;
467467
}
468468

469469
ASTScopeImpl *visitPatternBindingDecl(PatternBindingDecl *patternBinding,

0 commit comments

Comments
 (0)