aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.benjamin/15351-1.C
blob: 755c3608fcb21bf4c21e85758c49da45352a65a6 (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
// 981203 bkoz
// g++/15351 - test
// Special g++ Options: -fno-const-strings

#include <assert.h>

bool gtest;

struct acapulco {
  acapulco(const char *) { gtest = false; }
  acapulco(char *) { gtest = true; }
};

void foo(void)
{
  acapulco("some such string\n");
}

int main() 
{
  foo();
  if (!gtest)
    assert (0);

  return !gtest;
}