]> wimlib.net Git - wimlib/blobdiff - src/encoding.c
Stop force-inlining everything marked 'inline'
[wimlib] / src / encoding.c
index 6d40605b95e026222f5e56d624e92c277aa453dd..9337c9a16e6a277b2f4880058103b4cdd1377eee 100644 (file)
@@ -77,7 +77,7 @@ typedef unsigned (*decode_codepoint_fn)(const u8 *in, size_t remaining,
 /* Encode the Unicode codepoint @c and return the number of bytes used. */
 typedef unsigned (*encode_codepoint_fn)(u32 c, u8 *out);
 
-static inline unsigned
+static forceinline unsigned
 utf8_decode_codepoint(const u8 *in, size_t remaining, bool validate, u32 *c_ret)
 {
        if (likely(in[0] < 0x80)) { /* U+0...U+7F */
@@ -124,7 +124,7 @@ invalid:
        return 1;
 }
 
-static inline unsigned
+static forceinline unsigned
 utf8_encode_codepoint(u32 c, u8 *out)
 {
        if (likely(c < 0x80)) {
@@ -152,7 +152,7 @@ utf8_encode_codepoint(u32 c, u8 *out)
        return 4;
 }
 
-static inline unsigned
+static forceinline unsigned
 utf16le_decode_codepoint(const u8 *in, size_t remaining, bool validate,
                         u32 *c_ret)
 {
@@ -188,7 +188,7 @@ invalid:
        return min(remaining, 2);
 }
 
-static inline unsigned
+static forceinline unsigned
 utf16le_encode_codepoint(u32 c, u8 *out)
 {
        if (likely(c < 0x10000)) {
@@ -213,7 +213,7 @@ utf16le_encode_codepoint(u32 c, u8 *out)
  * If the input string is malformed, return @ilseq_err with errno set to EILSEQ.
  * If out of memory, return WIMLIB_ERR_NOMEM with errno set to ENOMEM.
  */
-static inline int
+static forceinline int
 convert_string(const u8 * const in, const size_t in_nbytes,
               u8 **out_ret, size_t *out_nbytes_ret,
               int ilseq_err,