[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: gnulib and C++
From: |
Bruno Haible |
Subject: |
Re: gnulib and C++ |
Date: |
Sat, 20 Feb 2010 19:54:22 +0100 |
User-agent: |
KMail/1.9.9 |
Hi John,
> But how about the following example? Does it have all the required
> features? It seems to work for me
Indeed, it works for me too. Apparently it was the
'using namespace gnulib_system_namespace;' that collided with
'using gnulib::open;'.
But there's a big caveat: I don't know whether including system
headers inside a namespace
namespace gnulib_system_namespace {
#include <fcntl.h>
}
is portable or not. There are several ways in which this can fail:
- system headers that don't support this,
- system headers that are included by 3rd-party library headers.
Until you have made a large-scale test of this approach, on an entire package,
I would not recommend it.
Bruno
- Re: gnulib and C++, (continued)
Re: gnulib and C++, Bruno Haible, 2010/02/18
Re: gnulib and C++, Bruno Haible, 2010/02/19
Re: gnulib and C++, Ralf Wildenhues, 2010/02/20