Lines Matching full:clang
6 <title>Clang - Expressive Diagnostics</title>
23 <p>In addition to being fast and functional, we aim to make Clang extremely user
28 Clang output to GCC 4.2's output in several examples.
31 that embed Clang and extract equivalent information through internal APIs.-->
36 <p>First, all diagnostics produced by clang include full column number
37 information. The clang command-line compiler driver uses this information
53 $ <b>clang -fsyntax-only format-strings.c</b>
61 <p>Clang captures and accurately tracks range information for expressions,
65 understand what is wrong based on the Clang error. Because clang prints a
75 $ <b>clang -fsyntax-only t.c</b>
84 out of clang contain exactly the pertinent information about what is wrong and
98 $ <b>clang -fsyntax-only t.c</b>
106 <p>Since Clang has range highlighting, it never needs to pretty print your code
113 $ <b>clang -fsyntax-only t.c</b>
138 $ <b>clang t.cc</b>
152 is going on. Clang aims to handle both cases well.<p>
162 $ <b>clang -fsyntax-only t.c</b>
170 system "pid_t" typedef is defined, Clang helpfully displays it with "aka".</p>
175 $ <b>clang -fsyntax-only t.c</b>
201 <p>and then compile it, we see that Clang is both providing more accurate information and is retaining the types as written by the user (e.g., "servers::Server", "::services::WebService"):
206 $ <b>clang -fsyntax-only t.cpp</b>
212 <p>Naturally, type preservation extends to uses of templates, and Clang retains information about how a particular template specialization (like <code>std::vector<Real></code>) was spelled within the source code. For example:</p>
217 $ <b>clang -fsyntax-only t.cpp</b>
226 in source code. When Clang produces a diagnostic about a particular
230 problem. In the following example, Clang warns about the use of a GCC
236 $ <b>clang t.c</b>
251 Clang provides the fix--add <code>template<></code>--as part of the
255 $ <b>clang t.cpp</b>
267 Clang helps you out by automatically printing instantiation information and
275 $ <b>clang -fsyntax-only t.c</b>
288 $ <b>clang -fsyntax-only t.c</b>
300 <p>In practice, we've found that Clang's treatment of macros is actually more useful in multiply nested
318 $ <b>clang t.c</b>
326 of GCC is completely useless for diagnosing the problem. Clang tries much harder
332 $ <b>clang t.c</b>
354 $ <b>clang t.cc</b>