In Cygwin on Windows PC I am using gcc v. 4.7.1.
But when I want to run this program terminal complains:
Sales_item.h:56:20: warning: defaulted and deleted functions only available with -std=c++11 or -std=gnu++11 [enabled by default]
Sales_item.h:70:27: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11 [enabled by default]
Sales_item.h:71:22: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11 [enabled by default]
1.5.2_Sales_item_sameISBN.cpp: In function ‘int main()’:
1.5.2_Sales_item_sameISBN.cpp:16:2: error: expected ‘;’ before ‘}’ token
In Terminal I also tried commands
-std=c++11
or std=c++11
or -std=gnu++11
or std=gnu++11
or -std=c++0x
or std=c++0x
but with no luck.
I am very sory, if I am bothering, but I don’t know whom can I ask.
I think the output us lying. -std=gnu++11 is not the default.
EDIT: Maybe they mean that non-static data member initializers are enabled by default and it gives you a warning because it doesn't exist in the version of C++ that is being used.