summaryrefslogtreecommitdiffstats
path: root/clang/unittests/AST/StmtPrinterTest.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/unittests/AST/StmtPrinterTest.cpp')
-rw-r--r--clang/unittests/AST/StmtPrinterTest.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/clang/unittests/AST/StmtPrinterTest.cpp b/clang/unittests/AST/StmtPrinterTest.cpp
index 0b334e768ff..c75cbdefbf2 100644
--- a/clang/unittests/AST/StmtPrinterTest.cpp
+++ b/clang/unittests/AST/StmtPrinterTest.cpp
@@ -32,6 +32,7 @@ using namespace tooling;
namespace {
void PrintStmt(raw_ostream &Out, const ASTContext *Context, const Stmt *S) {
+ assert(S != nullptr && "Expected non-null Stmt");
PrintingPolicy Policy = Context->getPrintingPolicy();
S->printPretty(Out, /*Helper*/ nullptr, Policy);
}
OpenPOWER on IntegriCloud