Quuxplusone / LLVMBugzillaTest

0 stars 0 forks source link

Lack of fixits for mismatched parenthesis, bracket or angle bracket #13258

Open Quuxplusone opened 12 years ago

Quuxplusone commented 12 years ago
Bugzilla Link PR13181
Status NEW
Importance P enhancement
Reported by Ivan Sorokin (vanyacpp@gmail.com)
Reported on 2012-06-22 15:47:37 -0700
Last modified on 2012-06-23 06:05:46 -0700
Version 3.0
Hardware PC Linux
CC anton@korobeynikov.info, dgregor@apple.com, llvm-bugs@lists.llvm.org
Fixed by commit(s)
Attachments
Blocks
Blocked by
See also
Currently clang shows which braces is unmatched:

ivan@liberty:~$ cat 3.cpp
void f()
{

ivan@liberty:~$ clang++ 3.cpp
3.cpp:3:1: error: expected '}'

^
3.cpp:2:1: note: to match this '{'
{
^

But it does not show which parenthesis, bracket or angle bracket is unmatched:

ivan@liberty:~$ clang++ 2.cpp
2.cpp:1:6: error: variable has incomplete type 'void'
void f(;
     ^
2.cpp:1:8: error: expected expression
void f(;
       ^
ivan@liberty:~$ clang++ 4.cpp
4.cpp:5:13: error: expected '>'
void f<int();
            ^
4.cpp:5:1: warning: declaration does not declare anything [-Wmissing-
declarations]
void f<int();
^~~~
Quuxplusone commented 12 years ago
1. Please add the testcase
2. Please make sure everything reproduces on 3.1 / trunk
Quuxplusone commented 12 years ago

Doh, sorry, missed that these are 'cat's'