[PATCH] D45603: Fix evaluation of `__has_include_next` during -frewrite-includes.
Volodymyr Sapsai via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Apr 12 16:47:43 PDT 2018
vsapsai added a comment.
To simplify reviewing additions to the test, here is the corresponding output
# 23 "/Users/vsapsai/Projects/llvm/llvm-project/clang/test/Frontend/rewrite-includes.c" 2
#if 0 /* expanded by -frewrite-includes */
#include "rewrite-includes9.h"
#endif /* expanded by -frewrite-includes */
# 23 "/Users/vsapsai/Projects/llvm/llvm-project/clang/test/Frontend/rewrite-includes.c"
# 1 "/Users/vsapsai/Projects/llvm/llvm-project/clang/test/Frontend/Inputs/rewrite-includes9.h" 1
#if (1)/*__has_include_next(<rewrite-includes9.h>)*/
#if 0 /* expanded by -frewrite-includes */
#include_next <rewrite-includes9.h>
#endif /* expanded by -frewrite-includes */
# 2 "/Users/vsapsai/Projects/llvm/llvm-project/clang/test/Frontend/Inputs/rewrite-includes9.h"
# 1 "/Users/vsapsai/Projects/llvm/llvm-project/clang/test/Frontend/Inputs/NextIncludes/rewrite-includes9.h" 1
included_line9
# 3 "/Users/vsapsai/Projects/llvm/llvm-project/clang/test/Frontend/Inputs/rewrite-includes9.h" 2
#endif
# 4 "/Users/vsapsai/Projects/llvm/llvm-project/clang/test/Frontend/Inputs/rewrite-includes9.h"
# 24 "/Users/vsapsai/Projects/llvm/llvm-project/clang/test/Frontend/rewrite-includes.c" 2
#if 0 /* expanded by -frewrite-includes */
#include "rewrite-includes9.h"
#endif /* expanded by -frewrite-includes */
#if (1)/*__has_include_next(<rewrite-includes9.h>)*/
#if 0 /* expanded by -frewrite-includes */
#include_next <rewrite-includes9.h>
#endif /* expanded by -frewrite-includes */
included_line9
#endif
https://reviews.llvm.org/D45603
More information about the cfe-commits
mailing list