[PATCH] D37861: preserving #pragma clang assume_nonnull in preprocessed output
Eli Friedman via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Sep 15 16:44:44 PDT 2017
efriedma added inline comments.
================
Comment at: lib/Frontend/PrintPreprocessedOutput.cpp:566
+ MoveToLine(Loc);
+ OS << "#pragma " << "clang assume_nonnull end";
+ setEmittedDirectiveOnThisLine();
----------------
Extra "<<"?
================
Comment at: test/Preprocessor/pragma_assume_nonnull.c:29
+ return bar(0) + foo(0); // expected-warning {{null passed to a callee that requires a non-null argument}}
+#endif
+}
----------------
This testcase is a little more complicated than it needs to be (the "#if"/"#ifndef" doesn't really add anything).
https://reviews.llvm.org/D37861
More information about the cfe-commits
mailing list