aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile2
-rw-r--r--README49
-rw-r--r--TODO15
3 files changed, 28 insertions, 38 deletions
diff --git a/Makefile b/Makefile
index af720e3..435a080 100644
--- a/Makefile
+++ b/Makefile
@@ -11,7 +11,7 @@ LIBS=-ldl
CFLAGS+=-m386 -malign-functions=0
DISAS=objdump -D -b binary -m i386
INSTALL=install
-VERSION=0.9
+VERSION=0.9.1
all: tcc
diff --git a/README b/README
index dbacf64..67bf04d 100644
--- a/README
+++ b/README
@@ -5,7 +5,7 @@ Features:
--------
- SMALL! You can compile and execute C code everywhere, for example on
- rescue disks (27KB for x86 TCC executable).
+ rescue disks (29KB for x86 TCC executable).
- FAST! tcc generates optimized x86 code. No byte code
overhead. Compiles, assemble and link about 7 times faster than 'gcc
@@ -87,35 +87,17 @@ when doing 'make test'.
Exact differences with ANSI C:
-----------------------------
-1) Preprocessor
-
- - the preprocessor tokens are the same as C. It means that in some
- rare cases, preprocessed numbers are not handled exactly as in ANSI
- C. This approach has the advantage of being simpler and FAST!
-
-2) C language
-
-- Cannot pass struct/union as value. Cannot assign struct/union (use
- memcpy instead).
+- Preprocessor: the preprocessor tokens are the same as C. It means
+ that in some rare cases, preprocessed numbers are not handled
+ exactly as in ANSI C. This approach has the advantage of being
+ simpler and FAST!
- Types: floating point numbers are not supported yet.
-- (BUG) 'char' and 'short' casts do not truncate correctly.
-
-- 'sizeof' may not work if too complex expression is given.
-
-- bit fields are not supported.
+- Bit fields are not supported.
-- L'c' or L"string" for wide chars are parsed but not handled as wchar_t.
-
-- Cannot initialize auto (=local) arrays with implicit size
- (workaround: specificy exact size in array declaration). Cannot
- initialize auto arrays with strings.
-
-3) Linking
-
-- extern variables must appear in a referenced dll and cannot appear
- in current source.
+- Linking: extern variables must appear in a referenced dll and cannot
+ appear in current source.
Supported ANSI C extensions:
---------------------------
@@ -126,15 +108,20 @@ Supported ANSI C extensions:
- '__func__' is a string variable containing the current function name (ISOC99).
-- variadic macros: __VA_ARGS__ can be used for function-like macros (ISOC99):
+- Variadic macros: __VA_ARGS__ can be used for function-like macros (ISOC99):
#define dprintf(level, __VA_ARGS__) printf(__VA_ARGS__).
-- declarations can appear anywhere in a block (ISOC99).
+- Declarations can appear anywhere in a block (ISOC99).
+
+- Array and struct/union elements can be initialized in any order by
+ using designators (.e.g. { [0].x = 1 }) (ISOC99).
+
+- Compound initializers are supported (e.g. int *p = (int []){ 1, 2,
+ 3}) (ISOC99).
-- array and struct/union elements can be initialized in any order by
- using designators (.e. { [0].x = 1 }) (ISOC99).
+- '#!' at the start of a line is ignored to allow scripting.
-- binary digits can be entered ('0b101' instead of '5').
+- Binary digits can be entered ('0b101' instead of '5').
Technical Description:
---------------------
diff --git a/TODO b/TODO
index 89aa798..052835f 100644
--- a/TODO
+++ b/TODO
@@ -2,18 +2,21 @@ TODO list:
Critical:
-- add structure assign.
-- fix 'char' and 'short' casts.
+- add float/double support (should be as small as possible while being
+ usable for RISC code generator too).
- 0 is pointer - fix type compare
-- fix L'' and L"" wide chars
- add message if external function or variable not found.
+- To check: 'sizeof' may not work if too complex expression is given.
+- fix 'char' and 'short' casts (in function parameters and in assignment).
- function pointers to forward reference (patch code generator).
-- add float/double support (should be as small as possible while being
- usable for RISC code generator too).
Not critical:
-- fix preprocessor symbol redefinition
+- fix multiple compound literals inits in blocks (ISOC99 normative
+ example - only relevant when using gotos! -> must add boolean
+ variable to tell if compound literal was already initialized).
+- fix L"\x1234" wide string case (need to store them as ints ?) */
+- fix preprocessor symbol redefinition
- better constant opt (&&, ||, ?:)
- add ELF executable and shared library output option (would be needed
for completness!).