aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* clarify support for functions returning an arrayJoe Soroka2011-03-081-5/+8
| | | | | | | | | previously, tcc would accept a prototype of a function returning an array, but not giving those functions bodies nor calling them. it seems that gcc has never supported them, so we should probably just error out... but it's possible that someone already using tcc includes some header that contains an unused prototype for one, so let's continue to support that.
* support c99 for-loop init decls (2nd attempt)Joe Soroka2011-03-081-3/+18
|
* partially revert e23194aJoe Soroka2011-03-082-20/+3
| | | | see http://lists.nongnu.org/archive/html/tinycc-devel/2011-03/msg00002.html
* revert last 3 commits. will find better way.Joe Soroka2011-03-081-96/+85
|
* small change to previous whitespace-only commitJoe Soroka2011-03-081-2/+2
|
* some indentation made prev patch pretty; removed itJoe Soroka2011-03-081-85/+81
|
* refactor post_type() to be explicit about its recursionJoe Soroka2011-03-081-5/+20
|
* added a note clarifying post_type() recursionJoe Soroka2011-03-081-0/+3
| | | | | | | | | some ancient pre-K&R C allows a function to return an array and the array brackets to be put after the arguments, such that "int c()[]" means the same as "int[] c()" see: http://llvm.org/bugs/show_bug.cgi?id=2399 http://java.sun.com/docs/books/jls/third_edition/html/classes.html#38703
* tccelf: allow multiply defined weak symbolsJoe Soroka2011-03-071-0/+2
|
* support c99 for-loop init declsJoe Soroka2011-03-074-4/+25
|
* use new weaken_symbol() to fix another real-world corner caseJoe Soroka2011-03-072-1/+4
|
* factor out symbol weakening into new functionJoe Soroka2011-03-071-10/+17
|
* weak redefinition of a symbol should weaken the originalJoe Soroka2011-03-072-0/+7
|
* __typeof(t) should not include storage modifiers of tJoe Soroka2011-03-062-0/+7
|
* tccpp: fix problem in preprocess_skip with empty #grischka2011-03-061-0/+2
| | | | | | | | for example: #ifdef stuff # /* some comment */ #endif
* unlink outfile firstChangming Xu2011-03-031-0/+1
| | | | file mode problem if the outfile already exists
* tccgen: handle __attribute((alias("target")))Joe Soroka2011-03-033-1/+27
|
* collapse branch in decl(), making way for next patchJoe Soroka2011-03-031-9/+9
|
* handle post-asm-label attributes on variablesJoe Soroka2011-03-032-25/+28
|
* tcc: fix weak attribute handlingJoe Soroka2011-03-022-6/+10
|
* Replace comment by a blankChangming Xu2011-03-011-7/+11
| | | | | | | | - fix my prev commit: put declaration above statements to stay c89 compatible - replace commit by a blank #define con(a, b) a/**/b this should yield a b, not ab
* tcc -E: append a ' ' after substChangming Xu2011-02-271-0/+10
| | | | | | | | | | We need a ' ' after subst of m in the following case #define m(name,r) name ## r #define m0(a,b,c) int m(a,b) c #define m1(a,b,c) int m(a,b)c m0(a, b, c); m1(a, b, c);
* i386-asm: support "pause" opcodeJoe Soroka2011-02-242-0/+2
|
* tccasm: support alternate .type syntaxesJoe Soroka2011-02-242-8/+23
|
* tccpp: treat gas comments in .S files as raw text, not tokensJoe Soroka2011-02-232-0/+6
|
* fix warning for tcctest.c introduced with my last commitJaroslav Kysela2011-02-221-1/+1
|
* fix another static struct init issue (arrays with unknown size at end)Jaroslav Kysela2011-02-223-31/+64
|
* Fix complex static initializers (handle additional '}' and '{' brackets)Jaroslav Kysela2011-02-222-4/+34
| | | | | | - added an example to test suite - the "warning: assignment discards qualifiers from pointer target type" is present but harmless
* tccpe: support leading underscore for symbolsgrischka2011-02-133-24/+42
| | | | | | | | | To make this the default, enable this line in libtcc.c:tcc_new: #if defined(TCC_TARGET_PE) && 0 s->leading_underscore = 1; and then recompile tcc and also libtcc1.a
* Add support of asm label for variables.Thomas Preud'homme2011-02-091-10/+23
| | | | | | | | Add support for asm labels for variables, that is the ability to rename a variable at assembly level with __asm__ ("newname") appended in its declaration. See http://gcc.gnu.org/onlinedocs/gcc-4.4.4/gcc/Asm-Labels.html for more details.
* Fix fct asm label: only valid for declarationThomas Preud'homme2011-02-093-58/+26
| | | | | | | | | - Fix function assembly label mechanism introduced in commit 9b09fc376e8c212a767c875e71ca003e3b9a0d2e to only accept alternative name for function declaration. - merge the code with the one introduced in commit 264a103610e3ee86b27b8cbb0e4ec81cd654d980. - Don't memorize token for asm label but directly the asm label.
* Fix incorrect use of basic type as bitflags.Thomas Preud'homme2011-02-071-4/+3
| | | | | Fix incorrect use of basic types as bitflags and inefficiency in commit cf36410e30b3c18be6c556158b2d0d0938f5b77d
* Complain for static fct declared w/o file scopeThomas Preud'homme2011-02-061-0/+4
| | | | | | | | | Error out on static function without file scope and give an explaination to the user This is a rewrite of e9406c09a3212ab3f120412a6bbdacb0cdd25deb but considering problems raised about static local function pointers in 632ee5a54076d417971ae7fa8a0c154441a71499.
* revert "update VT_STRUCT_SHIFT for new VT_VLA"Joe Soroka2011-02-042-2/+2
|
* Revert "Implement C99 Variable Length Arrays"Thomas Preud'homme2011-02-056-169/+33
| | | | This reverts commit a5a50eaafeea0d3ca47bc8fb6baf983743470c60.
* Revert "Reorder increasingly VT_* constants in tcc.h"Thomas Preud'homme2011-02-052-24/+24
| | | | This reverts commit 7f00523e2e1938fc3558164521fe3ecefd9e1747.
* Revert "Make TOK_alloca available for x86-64"Thomas Preud'homme2011-02-051-2/+0
| | | | This reverts commit af26ac56bfc584b70e20158e67f7035024076ec8.
* Revert "Disable C99 VLA when alloca is unavailable."Thomas Preud'homme2011-02-052-10/+2
| | | | This reverts commit e3e5d4ad7a475e30ea13ad1ba9f23e6210d5d431.
* update VT_STRUCT_SHIFT for new VT_VLAJoe Soroka2011-02-042-2/+2
|
* fix crash with get_tok_str() in skip()grischka2011-02-041-1/+1
| | | | | crash was triggered by numbers etc. as unexpected token, i.e. everything that requires additional information with the token.
* Disable C99 VLA when alloca is unavailable.Thomas Preud'homme2011-02-042-2/+10
| | | | | | | | | | | | | | | * Disable C99 VLA detection when alloca is unavailable and protect the new reference to TOK_alloca in decl_initializer in order to compile and run for architecture without working alloca. Not all code of C99 VLA is commented as it would required many ifdef stanza. Just the detection is commented so that VT_VLA is never set any type and the C99 VLA code is compiled but never called. However vpush_global_sym(&func_old_type, TOK_alloca) in decl_initializer needs to be protected by an ifdef stanza as well because it uses TOK_alloca. * include alloca and C99 VLA tests according to availability of TOK_alloca instead of relying on the current architecture
* Make TOK_alloca available for x86-64Thomas Preud'homme2011-02-041-0/+2
| | | | | | | TOK_alloca is now available on x86-64 so make put definition of TOK_alloca outside the BCHECK conditional macro definition but test if arch is i386 or x86-64. This makes C99 VLA works (understand compile) on x86-64.
* Reorder increasingly VT_* constants in tcc.hThomas Preud'homme2011-02-042-24/+24
|
* Implement C99 Variable Length ArraysThomas Preud'homme2011-02-046-33/+169
| | | | | | | Implement C99 Variable Length Arrays in tinycc: - Support VLA with multiple level (nested vla) - Update documentation with regards to VT_VLA - Add a testsuite in tcctest.c
* Correct Changelog wrt. to fix attributionThomas Preud'homme2011-02-041-1/+2
| | | | | Correctly attribute the patch bringing support for Debian GNU/kFreeBSD kernels to Pierre Chifflier.
* tcc: add sysinclude path with -B, like gcc doesJoe Soroka2011-02-021-1/+7
|
* add -isystem cmdline optionJoe Soroka2011-02-012-1/+6
|
* tcctest: plugged memleak (was polluting valgrind reports)Joe Soroka2011-02-011-0/+1
|
* tccasm: accept bracketed offset expressionsJoe Soroka2011-02-012-2/+15
|
* tccasm: accept "fmul/fadd st(0),st(n)" (dietlibc ipow/atanh)Joe Soroka2011-02-012-0/+6
|