[Libpqxx-general] Creating a connection object

Jeroen Vermeulen jtv at xs4all.nl
Fri Jun 13 13:10:00 UTC 2008


Vincent Predoehl wrote:
> On Jun 12, 2008, at 3:47 PM, Richard B. Kreckel wrote:

>> (Maybe, *every* public header file should have an include guard.)
> 
> a #pragma once at the top of each file should do it.

Pragma's are not a very nice solution: they're compiler-specific, and 
other compilers might warn about them.  But Richard is right: you're 
supposed to include headers like <pqxx/connection> which in turn include 
headers like <pqxx/connection.hxx>, and the only protection against 
double inclusion is in that first file.


Jeroen


More information about the Libpqxx-general mailing list