1 /* Test for strftime formats. Formats using C23 features. */
2 /* { dg-do compile } */
3 /* { dg-options "-std=c23 -pedantic -Wformat" } */
8 foo (char *s
, size_t m
, const struct tm
*tp
)
10 strftime (s
, m
, "%Ob", tp
);
11 strftime (s
, m
, "%OB", tp
);
12 /* It's not clear that %h equivalence to %b means %Oh is equivalent
13 to %Ob; here we expect %Oh to be diagnosed. */
14 strftime (s
, m
, "%Oh", tp
); /* { dg-warning "flag|modifier" "bad %Oh" } */