diff options
author | William S Fulton <wsf@fultondesigns.co.uk> | 2017-09-18 07:06:27 +0100 |
---|---|---|
committer | William S Fulton <wsf@fultondesigns.co.uk> | 2017-09-18 07:06:27 +0100 |
commit | 9e2a12416cf6ce7b926829aff353fe2d9019f135 (patch) | |
tree | fdaa597730a223d5cf6a44a159e888b88fbf1f7f /Source/CParse/parser.y | |
parent | 90ba174fcea1618af57aa594199541d47a89b7f6 (diff) | |
download | swig-9e2a12416cf6ce7b926829aff353fe2d9019f135.tar.gz |
Fix type promotion wrapping some non-trivial constant expressions
This was previously an integral type instead of a floating point type:
Diffstat (limited to 'Source/CParse/parser.y')
-rw-r--r-- | Source/CParse/parser.y | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Source/CParse/parser.y b/Source/CParse/parser.y index 273dadba8..3df98964d 100644 --- a/Source/CParse/parser.y +++ b/Source/CParse/parser.y @@ -6338,6 +6338,7 @@ valexpr : exprnum { $$ = $1; } break; } } + $$.type = promote($2.type, $4.type); } | LPAREN expr pointer RPAREN expr %prec CAST { $$ = $5; |