aboutsummaryrefslogtreecommitdiff
path: root/tcc.c
diff options
context:
space:
mode:
authorbellard <bellard>2006-10-28 14:15:37 +0000
committerbellard <bellard>2006-10-28 14:15:37 +0000
commit0bea5c7f21dbff5cab3b28002b32d8a84365bb75 (patch)
tree8aa4fe68da0c32721e06146e5d51b8f01638ec19 /tcc.c
parent24a19cc37e7884e9994a0fd63a96ba1ee31e207f (diff)
downloadtinycc-0bea5c7f21dbff5cab3b28002b32d8a84365bb75.tar.gz
tinycc-0bea5c7f21dbff5cab3b28002b32d8a84365bb75.tar.bz2
workaround for function pointers in conditional expressions (Dave Dodge)
Diffstat (limited to 'tcc.c')
-rw-r--r--tcc.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/tcc.c b/tcc.c
index 512c9e5..2289c86 100644
--- a/tcc.c
+++ b/tcc.c
@@ -7799,6 +7799,9 @@ static void expr_eq(void)
} else if (bt1 == VT_PTR || bt2 == VT_PTR) {
/* XXX: test pointer compatibility */
type = type1;
+ } else if (bt1 == VT_FUNC || bt2 == VT_FUNC) {
+ /* XXX: test function pointer compatibility */
+ type = type1;
} else if (bt1 == VT_STRUCT || bt2 == VT_STRUCT) {
/* XXX: test structure compatibility */
type = type1;