[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Tinycc-devel] Crash after "warning: storage mismatch for redefinition o
From: |
Pascal Cuoq |
Subject: |
[Tinycc-devel] Crash after "warning: storage mismatch for redefinition of 'L' " |
Date: |
Thu, 7 Feb 2019 14:59:32 +0000 |
In both version 0.9.25 and today's git version (commit
d27ea5155f47cb0c29699ef959b52b087dfff41a), tcc crashes while compiling the
following one-line invalid program:
enum myenum { L = -1 } L;
tcc crashes after emitting an error message:
address@hidden:~/tcc-2019-02-07$ bin/tcc -c enum.i
enum.i:1: warning: storage mismatch for redefinition of 'L'
Erreur de segmentation
GCC and Clang also consider the program as invalid, and emit the following
messages:
address@hidden:~/tcc-2019-02-07$ clang -c enum.i
enum.i:1:24: error: redefinition of 'L' as different kind of symbol
enum myenum { L = -1 } L;
^
enum.i:1:15: note: previous definition is here
enum myenum { L = -1 } L;
^
1 error generated.
address@hidden:~/tcc-2019-02-07$ gcc -c enum.i
enum.i:1:24: error: 'L' redeclared as different kind of symbol
enum myenum { L = -1 } L;
^
enum.i:1:15: note: previous definition of 'L' was here
enum myenum { L = -1 } L;
^
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Tinycc-devel] Crash after "warning: storage mismatch for redefinition of 'L' ",
Pascal Cuoq <=