This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH c/4.2] Fix PR c/27273


Hi, 

we were running into a tree check failure while due to passing all INTEGER_CST 
expressions to TREE_CONSTANT_OVERFLOW, while it can only handle those that 
match CONSTANT_CLASS_P. 

Bootstrapped, regtested with no additional failures on i686-suse-linux. 

2006-05-18  Dirk Mueller  <dmueller@suse.de>

        PR c/27273
        * c-common.c (convert_and_check): Only track TREE_OVERFLOW
        for CONSTANT_CLASS_P expressions.

--- c-common.c	(revision 113869)
+++ c-common.c	(working copy)
@@ -1077,7 +1077,7 @@ convert_and_check (tree type, tree expr)
   tree t = convert (type, expr);
   if (TREE_CODE (t) == INTEGER_CST)
     {
-      if (TREE_OVERFLOW (t))
+      if (TREE_OVERFLOW (t) && CONSTANT_CLASS_P (expr))
 	{
 	  TREE_OVERFLOW (t) = 0;
 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]