]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
re PR c++/26747 (bad break/continue is not detected until the gimplifier)
authorPaolo Carlini <paolo.carlini@oracle.com>
Mon, 26 Sep 2011 13:51:52 +0000 (13:51 +0000)
committerPaolo Carlini <paolo@gcc.gnu.org>
Mon, 26 Sep 2011 13:51:52 +0000 (13:51 +0000)
2011-09-26  Paolo Carlini  <paolo.carlini@oracle.com>

PR c++/26747
* cp-gimplify.c (get_bc_label): Remove obsolete diagnostics.

From-SVN: r179198

gcc/cp/ChangeLog
gcc/cp/cp-gimplify.c

index cd309042f876fee35b61ac78c6e3d225e50956e1..eb870c7bd71a319f571bcdaf347d5aabb9d6a0a7 100644 (file)
@@ -1,3 +1,8 @@
+2011-09-26  Paolo Carlini  <paolo.carlini@oracle.com>
+
+       PR c++/26747
+       * cp-gimplify.c (get_bc_label): Remove obsolete diagnostics.
+
 2011-09-25  Jason Merrill  <jason@redhat.com>
 
        * parser.c (inject_this_parameter): Split out from
index 6aeae75b06336d60c56c194691c28494deafbdf0..af45f5918468b16d0219895e48e61f36de20b3ba 100644 (file)
@@ -86,16 +86,6 @@ get_bc_label (enum bc_t bc)
 {
   tree label = bc_label[bc];
 
-  if (label == NULL_TREE)
-    {
-      if (bc == bc_break)
-       error ("break statement not within loop or switch");
-      else
-       error ("continue statement not within loop or switch");
-
-      return NULL_TREE;
-    }
-
   /* Mark the label used for finish_bc_block.  */
   TREE_USED (label) = 1;
   return label;