Fix my poor grammar from r210372

llvm-svn: 210387
This commit is contained in:
Richard Trieu 2014-06-06 23:56:22 +00:00
parent 28783da044
commit 731b501981
2 changed files with 8 additions and 8 deletions

View File

@ -2402,10 +2402,10 @@ def warn_impcast_pointer_to_bool : Warning<
InGroup<PointerBoolConversion>;
def warn_this_bool_conversion : Warning<
"'this' pointer cannot be null in well-defined C++ code; pointer may be "
"assumed always converted to true">, InGroup<UndefinedBoolConversion>;
"assumed to always convert to true">, InGroup<UndefinedBoolConversion>;
def warn_address_of_reference_bool_conversion : Warning<
"reference cannot be bound to dereferenced null pointer in well-defined C++ "
"code; pointer may be assumed always converted to true">,
"code; pointer may be assumed to always convert to true">,
InGroup<UndefinedBoolConversion>;
def warn_null_pointer_compare : Warning<

View File

@ -6,10 +6,10 @@
void test1(int &x) {
if (x == 1) { }
if (&x) { }
// expected-warning@-1{{reference cannot be bound to dereferenced null pointer in well-defined C++ code; pointer may be assumed always converted to true}}
// expected-warning@-1{{reference cannot be bound to dereferenced null pointer in well-defined C++ code; pointer may be assumed to always convert to true}}
if (!&x) { }
// expected-warning@-1{{reference cannot be bound to dereferenced null pointer in well-defined C++ code; pointer may be assumed always converted to true}}
// expected-warning@-1{{reference cannot be bound to dereferenced null pointer in well-defined C++ code; pointer may be assumed to always convert to true}}
}
class test2 {
@ -17,19 +17,19 @@ class test2 {
void foo() {
if (this) { }
// expected-warning@-1{{'this' pointer cannot be null in well-defined C++ code; pointer may be assumed always converted to true}}
// expected-warning@-1{{'this' pointer cannot be null in well-defined C++ code; pointer may be assumed to always convert to true}}
if (!this) { }
// expected-warning@-1{{'this' pointer cannot be null in well-defined C++ code; pointer may be assumed always converted to true}}
// expected-warning@-1{{'this' pointer cannot be null in well-defined C++ code; pointer may be assumed to always convert to true}}
}
void bar() {
if (x == 1) { }
if (&x) { }
// expected-warning@-1{{reference cannot be bound to dereferenced null pointer in well-defined C++ code; pointer may be assumed always converted to true}}
// expected-warning@-1{{reference cannot be bound to dereferenced null pointer in well-defined C++ code; pointer may be assumed to always convert to true}}
if (!&x) { }
// expected-warning@-1{{reference cannot be bound to dereferenced null pointer in well-defined C++ code; pointer may be assumed always converted to true}}
// expected-warning@-1{{reference cannot be bound to dereferenced null pointer in well-defined C++ code; pointer may be assumed to always convert to true}}
}
int &x;