Restore local type declarations list

This commit is contained in:
Robert Widmann
2017-01-05 18:10:18 -07:00
parent 9c7a6cfaa3
commit d2570cb964
14 changed files with 61 additions and 79 deletions

View File

@@ -52,18 +52,18 @@ static bool isResolvableScope(ScopeKind SK) {
llvm_unreachable("Unhandled ScopeKind in switch.");
}
Scope::Scope(Parser *P, ScopeKind SC, bool IsStaticallyInactiveConfigBlock)
Scope::Scope(Parser *P, ScopeKind SC, bool isInactiveConfigBlock)
: SI(P->getScopeInfo()),
HTScope(SI.HT, SI.CurScope ? &SI.CurScope->HTScope : nullptr),
PrevScope(SI.CurScope),
PrevResolvableDepth(SI.ResolvableDepth),
Kind(SC),
IsStaticallyInactiveConfigBlock(IsStaticallyInactiveConfigBlock) {
IsInactiveConfigBlock(isInactiveConfigBlock) {
assert(PrevScope || Kind == ScopeKind::TopLevel);
if (SI.CurScope) {
Depth = SI.CurScope->Depth + 1;
IsStaticallyInactiveConfigBlock |= SI.CurScope->IsStaticallyInactiveConfigBlock;
IsInactiveConfigBlock |= SI.CurScope->IsInactiveConfigBlock;
} else {
Depth = 0;
}
@@ -79,7 +79,7 @@ Scope::Scope(Parser *P, SavedScope &&SS):
PrevResolvableDepth(SI.ResolvableDepth),
Depth(SS.Depth),
Kind(SS.Kind),
IsStaticallyInactiveConfigBlock(SS.IsStaticallyInactiveConfigBlock) {
IsInactiveConfigBlock(SS.IsInactiveConfigBlock) {
SI.CurScope = this;
if (!isResolvableScope(Kind))