<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><br><div><div>On Aug 12, 2009, at 6:28 AM, Makslane Araújo Rodrigues wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div class="hmmessage" style="font-size: 10pt; font-family: Verdana; ">Hi again!<div><br></div><div>I want to catch the err_typecheck_call_too_few_args error (int the DiagnosticClient::HandleDiagnostic) and get the function call thats causes the error:</div><div><br></div><div>void func1(int a) {}</div><div><br></div><div>void func2()</div><div>{</div><div>   func1(); //error here</div><div>}</div><div><br></div><div>I've no idea how to get the information that is the func1 call is causing the error.</div></div></span></blockquote><div><br></div>the easiest way to find it is with grep:</div><div><br></div><div>$ cd llvm/tools/clang</div><div>$ grep err_typecheck_call_too_few_args lib/*/*<div>lib/Sema/SemaChecking.cpp:    return Diag(TheCall->getLocEnd(), diag::err_typecheck_call_too_few_args)</div><div>lib/Sema/SemaChecking.cpp:    return Diag(TheCall->getLocEnd(), diag::err_typecheck_call_too_few_args)</div><div>lib/Sema/SemaChecking.cpp:    return Diag(TheCall->getLocEnd(), diag::err_typecheck_call_too_few_args)</div><div>lib/Sema/SemaChecking.cpp:    return Diag(TheCall->getLocEnd(), diag::err_typecheck_call_too_few_args)</div><div>lib/Sema/SemaChecking.cpp:                          diag::err_typecheck_call_too_few_args)</div><div>lib/Sema/SemaChecking.cpp:                              diag::err_typecheck_call_too_few_args)</div><div>lib/Sema/SemaExpr.cpp:      return Diag(RParenLoc, diag::err_typecheck_call_too_few_args)</div><div><br></div><div>-Chris</div><div><br></div></div></body></html>