[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Tinycc-devel] old nocode_wanted problem
From: |
Sergey Korshunoff |
Subject: |
Re: [Tinycc-devel] old nocode_wanted problem |
Date: |
Wed, 25 Nov 2015 12:06:41 +0300 |
>> I assume that test now works
> No. I tried to restore a check and got an error message caused by
first part (before ':') of the cond expr. I will try to reduce a test.
A reduced test:
int main()
{
int romfsb_size = 1;
int nblocks_good_1 = __builtin_constant_p( 1 ) ?
({ 2; })
: 3;
int nblocks_good_2 = __builtin_constant_p( romfsb_size ) ?
2
: 3;
int nblocks_bad = __builtin_constant_p( romfsb_size ) ?
({ 2; })
: 3;
return 0;
}
A bad case: using a variable in __builtin_constant_p and computed
value ({ 2; }) together