Index: src/OFObject.m ================================================================== --- src/OFObject.m +++ src/OFObject.m @@ -38,11 +38,11 @@ #import "OFOutOfMemoryException.h" #import "OFOutOfRangeException.h" #import "macros.h" -#if defined(OF_APPLE_RUNTIME) || defined(OF_GNU_RUNTIME) +#if (defined(OF_APPLE_RUNTIME) && __OBJC2__) || defined(OF_GNU_RUNTIME) # import #elif defined(OF_OBJFW_RUNTIME) # import #elif defined(OF_OLD_GNU_RUNTIME) # import @@ -98,15 +98,15 @@ #ifdef NEED_OBJC_PROPERTIES_INIT extern BOOL objc_properties_init(); #endif -#if defined(OF_APPLE_RUNTIME) || defined(OF_GNU_RUNTIME) +#if (defined(OF_APPLE_RUNTIME) && __OBJC2__) || defined(OF_GNU_RUNTIME) static void uncaught_exception_handler(id exception) { - fprintf(stderr, "Unhandled exception:\n%s\n", + fprintf(stderr, "\nUnhandled exception:\n%s\n", [[exception description] UTF8String]); } #endif static void @@ -188,11 +188,11 @@ stderr); abort(); } #endif -#if defined(OF_APPLE_RUNTIME) || defined(OF_GNU_RUNTIME) +#if (defined(OF_APPLE_RUNTIME) && __OBJC2__) || defined(OF_GNU_RUNTIME) objc_setUncaughtExceptionHandler(uncaught_exception_handler); #endif #ifdef HAVE_OBJC_ENUMERATIONMUTATION objc_setEnumerationMutationHandler(enumeration_mutation_handler); Index: tests/OFStringTests.m ================================================================== --- tests/OFStringTests.m +++ tests/OFStringTests.m @@ -324,11 +324,11 @@ [@"\rFeh " hexadecimalValue] == 0xFE && [@"\r\t" hexadecimalValue] == 0) /* * These test numbers can be generated without rounding if we have IEEE - * floating point numbers, thus we can use == on then. + * floating point numbers, thus we can use == on them. */ TEST(@"-[floatValue]", [@"\t-0.25 " floatValue] == -0.25 && [@"\r-INFINITY\n" floatValue] == -INFINITY && isnan([@" NAN\t\t" floatValue]))