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: -fconst-strings #include <assert.h> bool gtest; struct acapulco { acapulco(const char *) { gtest = true; } acapulco(char *) { gtest = false; } }; void foo(void) { acapulco("some such string\n"); } int main() { foo(); if (!gtest) assert (0); return !gtest; }