Skip to content

Commit 96cf233

Browse files
committed
[SILPrinter] Hide VarInfo debug info if printing debuginfo is disabled
1 parent 3136d2e commit 96cf233

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/SIL/IR/SILPrinter.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1412,7 +1412,7 @@ class SILPrinter : public SILInstructionVisitor<SILPrinter> {
14121412
else
14131413
*this << ", var";
14141414

1415-
if ((Var->Loc || Var->Scope) && SM) {
1415+
if ((Var->Loc || Var->Scope) && SM && Ctx.printDebugInfo()) {
14161416
*this << ", (name \"" << Var->Name << '"';
14171417
if (Var->Loc)
14181418
printDebugLocRef(*Var->Loc, *SM);

0 commit comments

Comments
 (0)