https://gcc.gnu.org/bugzilla/show_bug.cgi?id=21038

Xi Ruoyao <xry111 at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |xry111 at gcc dot gnu.org

--- Comment #6 from Xi Ruoyao <xry111 at gcc dot gnu.org> ---
With latest GCC, it works for C++:

LANG= g++ t.c
t.c: In function 'void foo()':
t.c:4:11: error: expected '}' at end of input
    4 |     int k;
      |           ^
t.c:1:12: note: to match this '{'
    1 | void foo() {
      |            ^

But it's sometimes indeed completely misleading (PR109356).

Still does not work for C:

LANG= cc t.c
t.c: In function 'foo':
t.c:4:5: error: expected declaration or statement at end of input
    4 |     int k;
      |     ^~~

Can we close this or reset Component field?

Reply via email to