@@ -27,10 +27,12 @@ #import "OFObject.h" #import "OFSerialization.h" #import "OFJSONRepresentation.h" #import "OFMessagePackRepresentation.h" +OF_ASSUME_NONNULL_BEGIN + /*! @file */ @class OFConstantString; #if defined(__cplusplus) && __cplusplus >= 201103L @@ -1096,10 +1098,23 @@ */ - (void)enumerateLinesUsingBlock: (of_string_line_enumeration_block_t)block; #endif @end +#ifdef __cplusplus +extern "C" { +#endif +extern size_t of_string_utf8_encode(of_unichar_t, char*); +extern size_t of_string_utf8_decode(const char*, size_t, of_unichar_t*); +extern size_t of_string_utf16_length(const of_char16_t*); +extern size_t of_string_utf32_length(const of_char32_t*); +#ifdef __cplusplus +} +#endif + +OF_ASSUME_NONNULL_END + #import "OFConstantString.h" #import "OFMutableString.h" #import "OFString+Hashing.h" #import "OFString+JSONValue.h" #import "OFString+Serialization.h" @@ -1120,17 +1135,6 @@ * * TODO: Submit a patch for Clang that makes the boxing classes configurable! */ @interface NSString: OFString @end -#endif - -#ifdef __cplusplus -extern "C" { -#endif -extern size_t of_string_utf8_encode(of_unichar_t, char*); -extern size_t of_string_utf8_decode(const char*, size_t, of_unichar_t*); -extern size_t of_string_utf16_length(const of_char16_t*); -extern size_t of_string_utf32_length(const of_char32_t*); -#ifdef __cplusplus -} #endif