1 #include "onetwo.h" 2 3 struct InheritsFromOne : One { 4 int member = 47; 5 } inherits_from_one; 6 7 struct InheritsFromTwo : Two { 8 int member = 47; 9 } inherits_from_two; 10 11 struct OneAsMember { 12 member::One one; 13 int member = 47; 14 } one_as_member; 15 16 struct TwoAsMember { 17 member::Two two; 18 int member = 47; 19 } two_as_member; 20 21 array::One array_of_one[3]; 22 array::Two array_of_two[3]; 23 get_one()24result::One get_one() { return result::One(124); } get_two()25result::Two get_two() { return result::Two(224); } 26 27 // Note that there's also a function with the name func_shadow::One. 28 struct ShadowedOne : func_shadow::One { 29 int member = 47; 30 } shadowed_one; 31 main()32int main() { return get_one().member; } 33