Hi Petr,
Yes you are right, I didn’t know that! We’d better be standard conformant and remove the semicolons!
I actually used to think that namespaces need a semicolon just like classes. Recently I accidentally figured out that was not true when I forgot to write the semicolon in the packet-gen templates.
It would actually be great to always add -std=c++98 -pedantic to the compiler flags when using gcc under linux. Actually putting the following in tester.pri, for example, will do the job:
linux-g++{
QMAKE_CXXFLAGS += -std=c++98 -pedantic
}
Aside from complaining about the semicolons, the compiler complained a lot about long long which seems to be non-standard. I don’t know how we could work around the long long… it would have been nice to be able to compile with full standard conformance.
I digged an old post from Atul talking about some other compiler switches (see http://www.calitko.org/source-talk/583) which might be interesting to check.
Regards,
Peter
