<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<p>clang-tidy infers the language from the file extension or the
compile_commands.json if present (this is not the case when using
'--' like you do).</p>
<p>Please use '.cpp' as the file extension and try to set the
'-std=c++11' for now. Maybe your clang-tidy version is too old for
'c++1z'.<br>
</p>
<br>
<div class="moz-cite-prefix">Am 17.10.2017 um 11:08 schrieb Tiago
Macarios via cfe-dev:<br>
</div>
<blockquote type="cite"
cite="mid:CAKLVFYExT2xncRK1e1hUqF=5P4kZCf2Bhno-5j9CB606tZjC-g@mail.gmail.com">
<div dir="ltr">
<div>I am trying to run clang-tidy directly from the command
line:</div>
<div>clang-tidy <file> -- <compilation flags></div>
<div><br>
</div>
<div>and it seems like clang-tidy thinks it is parsing C:</div>
<div>...</div>
<div>error: 'uuid' attribute is not supported in C<br>
</div>
<div>...</div>
error: invalid argument '-std=c++1z' not allowed with 'C'
<div>...<br>
<div><br>
</div>
<div>How can I tell clang-tidy that the code is C++?</div>
<div><br>
</div>
<div>Tiago</div>
</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
cfe-dev mailing list
<a class="moz-txt-link-abbreviated" href="mailto:cfe-dev@lists.llvm.org">cfe-dev@lists.llvm.org</a>
<a class="moz-txt-link-freetext" href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev">http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev</a>
</pre>
</blockquote>
<br>
</body>
</html>