Opened 3 years ago

#345 new defect

Include error with g++ 4.8.2 and --std=gnu++11 flag

Reported by: fredrik@… Owned by: jtv
Priority: normal Component: other
Severity: Breaks Keywords:


I get the following fault when including libpqxx-4.0 into my small program:

./libpqxx/include/pqxx/compiler-public.hxx:180:14: warning: invalid suffix on literal; C++11 requires a space between literal and identifier [-Wliteral-suffix]

#error If you're using Visual C++, you'll need at least version 7 (.NET)

Command to build is: g++ -I./libpqxx/include/ --std=gnu++11 -Wall -o main main.cpp

and minimum program is:

#include "pqxx/pqxx"

int main(int argc, char *argv[]) {

return 0;


It seems to be a couple of "" that is missing, adding it around the error string makes it happy again. Without the --std=gnu++11 flag it compiles fine without patching it.

Change History (0)

Note: See TracTickets for help on using tickets.