Next: 8.3 Cyclomatic Complexity
Up: 8. SDCC Technical Data
Previous: 8.1.12 Peephole Optimizer
Contents
Index
8.2 ANSI-Compliance
Deviations from the compliance:
- functions are not always reentrant.
- structures cannot be assigned values directly, cannot be passed as
function parameters or assigned to each other and cannot be a return
value from a function, e.g.:
struct s { ... };
struct s s1, s2;
foo()
{
...
s1 = s2 ; /* is invalid in SDCC although allowed
in ANSI */
...
}
struct s foo1 (struct s parms) /* invalid in SDCC although
allowed in ANSI */
{
struct s rets;
...
return rets;/* is invalid in SDCC although allowed
in ANSI */
}
- 'long long' (64 bit integers)
not supported.
- 'double' precision floating point not
supported.
- No support for setjmp and longjmp
(for now).
- Old K&R style function declarations are NOT allowed.
foo(i,j) /* this old style of function declarations */
int i,j; /* are valid in ANSI but not valid in SDCC */
{
...
}
- functions declared as pointers
must be dereferenced during the call.
int (*foo)();
...
/* has to be called like this */
(*foo)(); /* ANSI standard allows calls to be made like
'foo()' */
Next: 8.3 Cyclomatic Complexity
Up: 8. SDCC Technical Data
Previous: 8.1.12 Peephole Optimizer
Contents
Index
Bernhard Held
2004-02-21