| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
| |
The Cabshelper is only used in 4 places, so we don't need a global
open. Furhtermore the String.t type is now inlined for Cabs to
avoid shadowing problems in Elab.ml
Bug 19872
|
|
|
|
|
|
| |
Format was only used in one place without explicit module prefix.
The same holds for Env.
Bug 19872
|
|
|
|
|
|
| |
Since anonymous struct members are kept in the fieldlist, the
fieldlist can never be empty in this case.
Bug 19872
|
|
|
|
|
|
|
| |
Instead of multiplying the array constant directly with the
size of the offset the cautious_mul function is used to detect
potential overflows.
Bug 20765
|
| |
|
|
|
|
|
|
| |
Gcc and clang do not raise an error for this, also it should work
for the last array element which can be without size.
Bug 20765
|
|
|
|
|
|
|
|
|
| |
The c standard allows member designators for offsetof. The current
implementation works by recursively combining the offset of each
of the member designators. For array access the size of the
subtypes is multiplied by the index and for members the offset of
the member is calculated.
Bug 20765
|
|
|
|
|
|
|
|
| |
The problem was that sub structs are were not correctly aligned.
The new version is much simpler and uses the sizeof_struct to
calculate the individual offsets and add them up to get correct
offest.
Bug 20765
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
The implementation of offsetof as macro in the form
((size_t) &((ty*) NULL)->member) has the problem that it cannot be
used everywhere were an integer constant expression is allowed,
for example in initiliazers of global variables and there is also
no check for the case that member is of bitifield type.
The new implementation adds a builtin function for this which is
replaced by an integer constant during elaboration.
Bug 20765
|
| |
|
|
|
|
| |
"try ...; true with _ -> false" is dangerous if "..." raises unexpected exceptions such as Out_of_memory or Stack_overflow.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
The naming of anonymous structs is performed by an additional step
in elab_struct_or_union_info instead of in elab_field_group.
Also the aux functions are renamed to access.
Bug 20003
|
|
|
|
|
|
| |
Instead of using idents the anonymous fileds get names of the
for <anon>_c where c is a counter of all anonymous members.
Bug 20003
|
|
|
|
| |
The warning for C11 features is now also triggered for _Noreturn.
|
|
|
|
|
|
| |
The warning missing declarations is now also triggered for
declarations without name in field lists of composite types if
the declaration is not an anonymous composite or a bitfield member.
|
|
|
|
|
| |
The anonymous members are kept but using them is still an error.
Bug 19907
|
|
|
|
|
|
| |
Now "expected at least %d" instead of "expected %d". Also improved
error message for __builtin_debug.
Bug 19872
|
|
|
|
|
|
|
|
| |
The only case where compcert raise a pedantic warning was for
implicit int parameters. This is the behavior of clang. However
since not all other pedantic warnings are supported the behavior
of gcc is adopted.
Bug 19872.
|
|
|
|
|
|
| |
In order to empty declarations it is necessary to distinguish
between forward declarations and empty declarations.
Bug 19859
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
Now the same warning is triggered for both cases, int to ptr and
ptr to int.
Bug 18004
|
| |
|
|
|
|
|
|
| |
This warning should be triggered if a feature is used that is not
part of the code CompCert C language.
Bug 18004
|
| |
|
|
|
|
|
|
|
|
| |
Some old errors/warnings messages were better before and are now
rephrased. Furthermore some formulations are rephrased to match the
used formulations of the ISO C stanard, e.g. storage class is
replaced with storage-class.
Bug 18004
|
| |
|
| |
|
|\ |
|
| |
| |
| |
| |
| |
| | |
The environment where the types are inserted is passed back to
allow introducing structs in k&r parameters.
Bug 19668
|
| |
| |
| |
| |
| |
| | |
The previous fix for duplicated members was also triggered for
unnamed members.
Bug 19665
|
| | |
|
|\| |
|
| |
| |
| |
| |
| |
| | |
In order to allow introducing structs in parameter definitions the
environment must keep the type information.
Bug 19602
|
| |
| |
| |
| |
| |
| | |
If a declaration of a composite is encountered it is also tested
if the kind is equal.
Bug 19630.
|
| |
| |
| |
| |
| |
| | |
Since some incomplete types are allowed in initialization just
test whether the default initilization exists.
Bug 19601
|
| |
| |
| |
| |
| |
| | |
New types introduced in casts are now inserted into the right
Environment and carried along.
Bug 19614.
|
| |
| |
| |
| | |
This reverts commit c64c4ab2526ad87a3506c9e1fdf31fa1446c16eb.
|
| |
| |
| |
| |
| | |
Allows adding struct definitions in function parameters.
Bug 19602.
|
| |
| |
| |
| |
| |
| | |
Initializers for function variables are not allowed. CompCert now
reports an error and exits.
Bug 19606
|
| |
| |
| |
| |
| |
| | |
Before the initializazion is computed we check wether the type is
incomplete.
Bug 19601
|
| |
| |
| |
| |
| |
| | |
CompCert now reports an error for usage of the va_start macro in
non variadic functions.
Bug 19600.
|