| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
| |
Discussed with Richard Smith.
llvm-svn: 245162
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
null comparison when the pointer is known to be non-null.
This catches the array to pointer decay, function to pointer decay and
address of variables. This does not catch address of function since this
has been previously used to silence a warning.
Pointer to bool conversion is under -Wbool-conversion.
Pointer to null comparison is under -Wtautological-pointer-compare, a sub-group
of -Wtautological-compare.
void foo() {
int arr[5];
int x;
// warn on these conditionals
if (foo);
if (arr);
if (&x);
if (foo == null);
if (arr == null);
if (&x == null);
if (&foo); // no warning
}
llvm-svn: 202216
|
| |
|
|
|
|
|
|
|
|
| |
This patch was submitted to the list for review and didn't receive a LGTM.
(In fact one explicit objection and one query were raised.)
This reverts commit r197295.
llvm-svn: 197299
|
| |
|
|
|
|
| |
Differential Revision: http://llvm-reviews.chandlerc.com/D2392
llvm-svn: 197295
|
| |
|
|
|
|
|
|
|
|
|
| |
The tests were perhaps made too relaxed in r197164 when we switched to the new
MinGW ABI. This makes sure we check explicitly for an optional thiscall
attribute and nothing else.
We should still look into whether we should print these attributes at all in
these cases.
llvm-svn: 197252
|
| |
|
|
|
|
|
| |
GCC 4.7 changed the MingW ABI. On the clang side this means that methods now
have the thiscall calling convention by default.
llvm-svn: 197164
|
| |
|
|
|
|
|
| |
DR61 affirms that expressions containing unresolved member access should
be disallowed when performing "address of" operations.
llvm-svn: 183723
|
| |
|
|
|
|
| |
VerifyDiagnosticConsumer, make the necessary adjustment to 580 test-cases which will henceforth require this new directive.
llvm-svn: 166280
|
| |
|
|
|
|
|
|
|
|
|
| |
Moves the bool bail-out down a little in SemaChecking - so now
-Wnull-conversion and -Wliteral-conversion can fire when the target type is
bool.
Also improve the wording/details in the -Wliteral-conversion warning to match
the -Wconstant-conversion.
llvm-svn: 156826
|
| |
|
|
|
|
| |
going to be a pointer-to-member constant. Fixes <rdar://problem/10544564>.
llvm-svn: 146587
|
| |
|
|
|
|
| |
functions, e.g., (&f)(0). Fixes <rdar://problem/9803316>.
llvm-svn: 141877
|
| |
|
|
|
|
|
|
|
|
|
| |
and DefaultFunctionArrayLvalueConversion. To prevent
significant regression for should-this-be-a-call fixits,
and to repair some such regression from the introduction of
bound member placeholders, make those placeholder checks
try to build calls appropriately. Harden the build-a-call
logic while we're at it.
llvm-svn: 141738
|
| |
|
|
|
|
|
|
|
| |
overload, so that we actually do the resolution for full expressions
and emit more consistent, useful diagnostics. Also fixes an IRGen
crasher, where Sema wouldn't diagnose a resolvable bound member
function template-id used in a full-expression (<rdar://problem/9108698>).
llvm-svn: 127747
|
| |
|
|
|
|
| |
Faisal Vali, tweaked by me. Fixes PR8230.
llvm-svn: 118400
|
| |
|
|
| |
llvm-svn: 116287
|
| |
|
|
|
|
|
| |
actually resolves to a particular function. Fixes PR8181, from Faisal
Vali!
llvm-svn: 114331
|
|
|
llvm-svn: 111997
|