testsuite: Add testcase for already fixed PR [PR119226]

This was fixed in PR119219 r15-7981 commit.

2025-03-12  Jakub Jelinek  <jakub@redhat.com>

	PR middle-end/119226
	* gcc.c-torture/compile/pr119226.c: New test.
This commit is contained in:
Jakub Jelinek 2025-03-12 10:48:31 +01:00 committed by Jakub Jelinek
parent e406994e31
commit bb83e83cad

View file

@ -0,0 +1,12 @@
/* PR middle-end/119226 */
char a[64];
void bar (void);
void
foo (int x)
{
char *b = a + __builtin_strcspn (a, x ? "" : "ab");
if (b[0])
bar ();
}