blob: 11ed7ec08930caa4c625725d9abefa0f032dfb21 [file] [log] [blame]
/* { dg-do compile } */
/* { dg-options "-fsanitize=integer-divide-by-zero" } */
void
foo (int i)
{
switch (i)
case 0 * (1 / 0): /* { dg-warning "division by zero" } */
; /* { dg-error "is not a constant.expression" "" { target *-*-* } .-1 } */
}