aboutsummaryrefslogtreecommitdiff
path: root/gcc/treelang/treetree.c
diff options
context:
space:
mode:
authorJames A. Morrison <phython@gcc.gnu.org>2005-02-26 14:01:03 +0000
committerJames A. Morrison <phython@gcc.gnu.org>2005-02-26 14:01:03 +0000
commitc93e9e16fb2f98cf147efa3710c7d41fceecff54 (patch)
tree3ee2fa5b5b26dee05ba50d9f906279dd477341fc /gcc/treelang/treetree.c
parent03e3ca0d2b16e568ae6060e3a77109e0c371ce27 (diff)
downloadgcc-c93e9e16fb2f98cf147efa3710c7d41fceecff54.zip
gcc-c93e9e16fb2f98cf147efa3710c7d41fceecff54.tar.gz
gcc-c93e9e16fb2f98cf147efa3710c7d41fceecff54.tar.bz2
parse.y: Do comparisons as the type of the first expression.
2005-02-26 James A. Morrison <phython@gcc.gnu.org> * parse.y: Do comparisons as the type of the first expression. * treetree.c (tree_code_get_integer_value): Build integer constants with the proper type. From-SVN: r95578
Diffstat (limited to 'gcc/treelang/treetree.c')
-rw-r--r--gcc/treelang/treetree.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/treelang/treetree.c b/gcc/treelang/treetree.c
index eef293b..dcb7cd3 100644
--- a/gcc/treelang/treetree.c
+++ b/gcc/treelang/treetree.c
@@ -650,7 +650,8 @@ tree_code_get_integer_value (unsigned char* chars, unsigned int length)
for (ix = start; ix < length; ix++)
val = val * 10 + chars[ix] - (unsigned char)'0';
val = val*negative;
- return build_int_cst_wide (NULL_TREE,
+ return build_int_cst_wide (start == 1 ?
+ integer_type_node : unsigned_type_node,
val & 0xffffffff, (val >> 32) & 0xffffffff);
}