At 03:49 PM 3/7/2003, Howard Hinnant wrote:[SNIP my previous message]
I'm a Metrowerks expert, but not a boost expert. Your project is set up to use MSL C which correctly puts ptrdiff_t into namespace std. The above code can't find ::ptrdiff_t because <cstddef> only defined std::ptrdiff_t.
It looks to me like BOOST_NO_STDC_NAMESPACE is being mistakenly defined somewhere.
Try compiling libs/config/config_info.cpp and running it. The output will tell you what the configuration looks like. It will identify the platform, compiler, library, and the important macros defined for each. Look for macros which are obviously wrong, such as BOOST_NO_STDC_NAMESPACE.
I can't compile the file; the BOOST_NO_STDC_NAMESPACE mistake results in a compilation error (which prevents running). How would I override this particular macro?
I could preprocess the file, and here are the results, removing the macro printings that result two identical strings (which I think means that the macro isn't defined at all):
//================================================================== void print_compiler_macros() { std::cout << "Metrowerks CodeWarrior C++ version 0x3003"<< "\n"; print_macro("__cplusplus", "=199711L") ; print_macro("__STDC__", "=1") ; print_macro("__STDC_VERSION__", "=199901L") ; print_macro("__MWERKS__", "=0x3003") ; print_macro("__MSL__", "=0x00008003") ; print_macro("__MSL_CPP__", "=0x8300") ; print_macro("__embedded_cplusplus", "=0") ; print_macro("__fourbyteints__", "=1") ; print_macro("__IEEEdoubles__", "=1") ; print_macro("__profile__", "=0") ; print_macro("__powerc", "=1") ; print_macro("__POWERPC__", "=1") ; print_macro("__MACH__", "=1") ; print_macro("__APPLE__", "=1") ; print_macro("powerc", "=1") ; print_macro("__STDC_HOSTED__", "=0") ; } void print_stdlib_macros() { std::cout << "Metrowerks Standard Library version 0x8300"<< std::endl; // No macros in this section were defined (D.W.) } void print_platform_macros() { std::cout << "Detected Platform: "<< "Mac OS"<< std::endl; print_sign("char", char()) ; print_sign("wchar_t", wchar_t()) ; print_byte_order("byte order for type short", short()) ; print_byte_order("byte order for type int", int()) ; print_byte_order("byte order for type long", long()) ; print_expression("sizeof(wchar_t)", sizeof(wchar_t)); ; print_expression("sizeof(short)", sizeof(short)); ; print_expression("sizeof(int)", sizeof(int)); ; print_expression("sizeof(long)", sizeof(long)); ; print_expression("sizeof(float)", sizeof(float)); ; print_expression("sizeof(double)", sizeof(double)); ; print_expression("sizeof(long double)", sizeof(long double)); ; print_macro("CHAR_BIT", "=8") ; print_macro("CHAR_MAX", "=0x7f") ; print_macro("WCHAR_MAX", "=0x7FFFFFFFU") ; print_macro("SHRT_MAX", "=0x7fff") ; print_macro("INT_MAX", "=0x7fffffff") ; print_macro("LONG_MAX", "=0x7fffffffL") ; print_macro("LLONG_MAX", "=0x7fffffffffffffffLL") ; print_macro("_POSIX_CHOWN_RESTRICTED", "=1") ; print_macro("_POSIX_JOB_CONTROL", "=") ; print_macro("_POSIX_NO_TRUNC", "=1") ; print_macro("_POSIX_THREAD_ATTR_STACKADDR", "=") ; print_macro("_POSIX_THREAD_ATTR_STACKSIZE", "=") ; print_macro("_POSIX_THREAD_PRIO_INHERIT", "=") ; print_macro("_POSIX_THREAD_PRIO_PROTECT", "=") ; print_macro("_POSIX_THREAD_PRIORITY_SCHEDULING", "=") ; print_macro("_POSIX_THREADS", "=") ; print_macro("_POSIX_VDISABLE", "=((unsigned char)'\\377')") ; print_macro("_POSIX_VERSION", "=198808L") ; print_macro("_POSIX2_VERSION", "=199212L") ; } void print_boost_macros() { std::cout << "Boost version "<< "102900"<< std::endl; print_macro("BOOST_DECL", "=") ; print_macro("BOOST_HAS_GETTIMEOFDAY", "=") ; print_macro("BOOST_HAS_HASH", "=") ; print_macro("BOOST_HAS_LONG_LONG", "=") ; print_macro("BOOST_HAS_PTHREADS", "=") ; print_macro("BOOST_HAS_SCHED_YIELD", "=") ; print_macro("BOOST_HAS_STDINT_H", "=") ; print_macro("BOOST_HAS_SLIST", "=") ; print_macro("BOOST_HAS_THREADS", "=") ; print_macro("BOOST_HAS_UNISTD_H", "=") ; print_macro("BOOST_MSVC6_MEMBER_TEMPLATES", "=") ; print_macro("BOOST_NESTED_TEMPLATE", "=template") ; print_macro("BOOST_NO_CTYPE_FUNCTIONS", "=") ; print_macro("BOOST_NO_CWCHAR", "=") ; print_macro("BOOST_NO_CWCTYPE", "=") ; print_macro("BOOST_NO_MS_INT64_NUMERIC_LIMITS", "=") ; print_macro("BOOST_NO_STDC_NAMESPACE", "=") ; print_macro("BOOST_NO_SWPRINTF", "=") ; print_macro("BOOST_STD_EXTENSION_NAMESPACE", "=Metrowerks") ; } //==================================================================
Daryle
_______________________________________________ Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost