summaryrefslogtreecommitdiff
path: root/support/regression/tests/gcc-torture-execute-pr60062.c
blob: 1b5b0ce8be95b058a1a505beaf1e2e681f8c4a8e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
/*
   pr60062.c from the execute part of the gcc torture tests.
 */

#include <testfwk.h>

#ifdef __SDCC
#pragma std_c99
#pragma disable_warning 85
#endif

#include <string.h>

/* PR target/60062 */

int a;

static void
foo (const char *p1, int p2)
{
  (void)p2;
  ASSERT (strcmp (p1, "hello") == 0);
}

static void
bar (const char *p1)
{
  ASSERT (strcmp (p1, "hello") == 0);
}

void
testTortureExecute (void)
{
  foo ("hello", a);
  bar ("hello");
}