<html>
<head>
<base href="https://llvm.org/bugs/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW " title="NEW --- - __has_include not reported by "clang -dM -E - < /dev/null"" href="https://urldefense.proofpoint.com/v2/url?u=https-3A__llvm.org_bugs_show-5Fbug.cgi-3Fid-3D23951&d=AwMBaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=pF93YEPyB-J_PERP4DUZOJDzFVX5ZQ57vQk33wu0vio&m=0kUsoZihWaoy1TE_WsBGSVKhAHlZVlL1ifLldk8N0HQ&s=o0_cWRSADweopDol4AKdhaVan-KmkUbritAsebsaAj8&e=">23951</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>__has_include not reported by "clang -dM -E - < /dev/null"
</td>
</tr>
<tr>
<th>Product</th>
<td>clang
</td>
</tr>
<tr>
<th>Version</th>
<td>3.6
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>Driver
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedclangbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>nikolai.kosjar@digia.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvmbugs@cs.uiuc.edu
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr></table>
<p>
<div>
<pre>__has_include (and also *_next) is *not* reported by "clang -dM -E - <
/dev/null" but it's there:
~/work/clang-bugs % clang-3.6 --version
Ubuntu clang version 3.6.0-2ubuntu1~trusty1 (tags/RELEASE_360/final) (based on
LLVM 3.6.0)
Target: x86_64-pc-linux-gnu
Thread model: posix
~/work/clang-bugs % cat confirmPredefinedHasIncludeMacro.cpp
#if defined(__has_include)
# error "OK, __has_include"
#endif
~/work/clang-bugs % clang-3.6 -dM -E - < /dev/null | grep has_include
zsh: done clang-3.6 -dM -E - < /dev/null |
zsh: exit 1 grep --color=auto has_include
By the way, is this the preferred way to check for predefined macros in clang?</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>