Skip to content

Commit 64a48b2

Browse files
author
David Ungar
committed
---
yaml --- r: 313343 b: refs/heads/A-7-9-astscope-no-nesting c: 66321e5 h: refs/heads/master i: 313341: 5f79244 313339: 98423ae 313335: 573af22 313327: 584eb7c 313311: c533934 313279: a3c8763 313215: 2634f24 313087: 0deff4b 312831: abb714e 312319: dc9fcb4 311295: 881526f
1 parent 4490bcd commit 64a48b2

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1416,4 +1416,4 @@ refs/tags/swift-DEVELOPMENT-SNAPSHOT-2019-06-30-a: 507bcc31605fe02fdc5d1fadca1bd
14161416
refs/tags/swift-DEVELOPMENT-SNAPSHOT-2019-07-01-a: 503b7173a821a8c714628503dfe1d865d9fb6804
14171417
refs/tags/swift-DEVELOPMENT-SNAPSHOT-2019-07-02-a: 1c3a1b43d7a730aa133f36327138335ce5b27765
14181418
refs/tags/swift-DEVELOPMENT-SNAPSHOT-2019-07-03-a: 67fd73eeb45b2a74028c6799704b79b1de9b7c87
1419-
refs/heads/A-7-9-astscope-no-nesting: b4f6527f4549c8ff934536952208772c0045c920
1419+
refs/heads/A-7-9-astscope-no-nesting: 66321e5552a0acaf03fb2265f19ca0adc99f3e16

branches/A-7-9-astscope-no-nesting/lib/AST/ASTPrinter.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3374,7 +3374,11 @@ void Decl::print(raw_ostream &OS, const PrintOptions &Opts) const {
33743374

33753375
bool Decl::print(ASTPrinter &Printer, const PrintOptions &Opts) const {
33763376
PrintAST printer(Printer, Opts);
3377-
return printer.visit(const_cast<Decl *>(this));
3377+
auto easl = getASTContext().LangOpts.EnableASTScopeLookup;
3378+
getASTContext().LangOpts.EnableASTScopeLookup = false;
3379+
auto r = printer.visit(const_cast<Decl *>(this));
3380+
getASTContext().LangOpts.EnableASTScopeLookup = easl;
3381+
return r;
33783382
}
33793383

33803384
bool Decl::shouldPrintInContext(const PrintOptions &PO) const {

0 commit comments

Comments
 (0)