1 // g++ 1.36.1 bug 900205_03
3 // Section 6.6.3 of the cfront 2.0 Reference Manual says "A return statement
4 // without an expression can be used only in functions that do not return
5 // a value, that is, a function with the return value type void..."
7 // Also in 6.6.3: "Flowing off the end of a function is equivalent to a
8 // return with no value; this is illegal in a value returning function."
10 // In contrast to the manual, g++ does not generate ERRORs for cases of
11 // "flowing off the end" of non-void functions.
13 // keywords: return statements, return type, void return, implicit return
15 // Special g++ Options: -Wreturn-type -pedantic-errors
19 int global_function_0 () {
22 struct00 global_function_1 () {
27 int struct0_member_function_0 () {
30 struct0 struct0_member_function_1 () {
36 int struct1_member_function_0 ();
38 struct1 struct1_member_function_1 ();
42 int struct1_member_function_0 () {
45 struct1 struct1::struct1_member_function_1 () {
48 int main () { return 0; }