
Jonathan Wakely ha escrito:
On Tue, May 31, 2005 at 12:32:39PM +0200, Joaqu?n M? L?pez Mu?oz wrote:
Jonathan Wakely ha escrito:
On Tue, May 31, 2005 at 08:36:41AM +0200, Joaqu?n M? L?pez Mu?oz wrote:
Martin Wille posted about this a couple of days ago (http://lists.boost.org/boost-testing/2005/05/1216.php), but I'm afraid it could have passed unnoticed.
Some tests from Boost.(Assign|Range|PointerContainer) have the following layout
#include<...>
using namespace std; using namespace boost;
...
#include <boost/test/unit_test.hpp>
having the using directives before boost/test/unit_test.hpp is AFAICS illegal and does indeed cause problems with GCC 3.4.x and GCC 4.x, see for instance http://tinyurl.com/8payc
That's a libstdc+ bug which has been fixed in GCC's CVS.
Actually, I've just realised the fix isn't on the 3.4 branch, only 4.x
(The problem is revealed because of the using directives before the header, which are legal, but can be dangerous)
Yes, giving it a second thought it is probably legal... Anyway, could you confirm whether moving the includes up fixes the problem?
I'm having serious hardware nightmares at work but I'll try to test it later today.
If anyone else wants to investigate it requires GCC 3.4 (any version) and you need to compile with _GLIBCXX_DEBUG defined.
Did you have a chance to try? Thank you, Joaquín M López Muñoz Telefónica, Investigación y Desarrollo