Putting builtins in the std namespace
Mark Mitchell
mark@codesourcery.com
Thu Oct 19 12:18:00 GMT 2000
Benjamin --
I'm trying to digest your example. Are you saying that you want:
extern "C" {typedef unsigned int size_t ;}
void *operator new (std::size_t) throw (std::bad_alloc);
to compile, with -fhonor-std, without any definition of `std::size_t'
in view? There's an `#if 1' in your code that I don't understand.
I think I understand this variant:
namespace _C_legacy {
extern "C" {
typedef unsigned int size_t;
}
} // namespace _C_legacy
namespace std {
using _C_legacy::size_t;
} // namespace std
void *operator new (std::size_t) throw (std::bad_alloc);
That, makes sense to me, and I'll try to get that working shortly.
--
Mark Mitchell mark@codesourcery.com
CodeSourcery, LLC http://www.codesourcery.com
More information about the Gcc-patches
mailing list