[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Tinycc-devel] bug: function pointers are broken
From: |
Lukas Mai |
Subject: |
[Tinycc-devel] bug: function pointers are broken |
Date: |
Mon, 13 Dec 2004 07:08:48 +0100 (MET) |
Hello,
I've just downloaded and compiled tcc, and I'm quite impressed by its
size and speed. However, function pointers seem to be broken. The
following examples are all valid C89:
bug1.c:
int main(void) {
(*main)();
}
bug1.c:2: pointer expected
bug2.c:
int main(void) {
(1 ? main : main)();
}
bug2.c:2: function pointer expected
bug3.c:
int main(void) {
int (*x)(void) = 1 ? main : main;
x();
/* attempted workaround for bug2 */
}
bug3.c:2: warning: assignment makes pointer from integer without a cast
All of them were generated with tcc version 0.9.22 - Tiny C Compiler -
Copyright (C) 2001-2004 Fabrice Bellard.
I hope you can fix these problems (if you find the time :-).
TIA, Lukas
--
GMX ProMail mit bestem Virenschutz http://www.gmx.net/de/go/mail
+++ Empfehlung der Redaktion +++ Internet Professionell 10/04 +++
- [Tinycc-devel] bug: function pointers are broken,
Lukas Mai <=