diff options
| author | David Majnemer <david.majnemer@gmail.com> | 2016-02-19 07:15:33 +0000 |
|---|---|---|
| committer | David Majnemer <david.majnemer@gmail.com> | 2016-02-19 07:15:33 +0000 |
| commit | c919f5f96459f5ca9ec3a8e902e3451eeae9648a (patch) | |
| tree | 48258da2aa500354b4627d4f67863c486ff43156 /clang/test/SemaCXX/typo-correction.cpp | |
| parent | 5eeb41c173738cbde5b2b9df3301b558207b9271 (diff) | |
| download | bcm5719-llvm-c919f5f96459f5ca9ec3a8e902e3451eeae9648a.tar.gz bcm5719-llvm-c919f5f96459f5ca9ec3a8e902e3451eeae9648a.zip | |
Correct typos after acting on invalid subscript expressions
llvm-svn: 261312
Diffstat (limited to 'clang/test/SemaCXX/typo-correction.cpp')
| -rw-r--r-- | clang/test/SemaCXX/typo-correction.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/clang/test/SemaCXX/typo-correction.cpp b/clang/test/SemaCXX/typo-correction.cpp index ae6bfa53c93..48597ded152 100644 --- a/clang/test/SemaCXX/typo-correction.cpp +++ b/clang/test/SemaCXX/typo-correction.cpp @@ -670,3 +670,12 @@ struct B0 { int : 0 | // expected-error {{invalid operands to binary expression}} (struct B0)e; // expected-error {{use of undeclared identifier}} }; + +namespace { +struct a0is0 {}; +struct b0is0 {}; +int g() { + 0 [ // expected-error {{subscripted value is not an array}} + sizeof(c0is0)]; // expected-error {{use of undeclared identifier}} +}; +} |

