aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/cpp23/attr-assume8.C
blob: 3c7a62f7fc4e941b7993e0ad0e79a18fe72bcfaf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
// PR tree-optimization/107369
// { dg-do compile { target c++11 } }
// { dg-options "-O1" }

void
foo (int x)
{
  if (x == 1)
    goto l1;			// { dg-message "from here" }

  [[assume (({ l1:; 1; }))]];	// { dg-error "jump to label 'l1'" }
}				// { dg-message "enters statement expression" "" { target *-*-* } .-1 }