diff options
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.bugs/900220_02.C')
-rwxr-xr-x | gcc/testsuite/g++.old-deja/g++.bugs/900220_02.C | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.bugs/900220_02.C b/gcc/testsuite/g++.old-deja/g++.bugs/900220_02.C new file mode 100755 index 0000000..cf039f6 --- /dev/null +++ b/gcc/testsuite/g++.old-deja/g++.bugs/900220_02.C @@ -0,0 +1,30 @@ +// g++ 1.36.1 bug 900220_02 + +// g++ treats plain `char' and `unsigned char' as different types, however +// it fails to treat `signed char' as being a different type from plain +// `char' as called for by both the ANSI C standard and the C++ reference +// manual. + +// keywords: plain char type, signed char type, unsigned char type, overloading + +void overloaded (char) { +} + +void overloaded (signed char) { // gets bogus error +} + +void overloaded (unsigned char) { +} + +void global_function () +{ + char c = 0; + signed char sc = 0; + unsigned char uc = 0; + + overloaded (c); + overloaded (sc); + overloaded (uc); +} + +int main () { return 0; } |