diff options
author | Mike Pall <mike> | 2021-06-01 05:14:18 +0200 |
---|---|---|
committer | Mike Pall <mike> | 2021-06-01 05:14:18 +0200 |
commit | edd5cbadc5cdc7b5b66d5340ee97c5abe5a3892a (patch) | |
tree | 053c8bb18f0b9de559a4b712062fd99e96849be7 /src/lj_strfmt.h | |
parent | 50d6883e6027c4c2f9a5e495fee6b7fff1bd73c9 (diff) | |
download | luajit-edd5cbadc5cdc7b5b66d5340ee97c5abe5a3892a.tar.gz luajit-edd5cbadc5cdc7b5b66d5340ee97c5abe5a3892a.tar.bz2 luajit-edd5cbadc5cdc7b5b66d5340ee97c5abe5a3892a.zip |
String buffers, part 2c: abstract out string.format.
Sponsored by fmad.io.
Diffstat (limited to 'src/lj_strfmt.h')
-rw-r--r-- | src/lj_strfmt.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/lj_strfmt.h b/src/lj_strfmt.h index fa25dcd0..cb2c7360 100644 --- a/src/lj_strfmt.h +++ b/src/lj_strfmt.h | |||
@@ -95,7 +95,9 @@ LJ_FUNC SBuf * LJ_FASTCALL lj_strfmt_putint(SBuf *sb, int32_t k); | |||
95 | LJ_FUNC SBuf * LJ_FASTCALL lj_strfmt_putnum(SBuf *sb, cTValue *o); | 95 | LJ_FUNC SBuf * LJ_FASTCALL lj_strfmt_putnum(SBuf *sb, cTValue *o); |
96 | #endif | 96 | #endif |
97 | LJ_FUNC SBuf * LJ_FASTCALL lj_strfmt_putptr(SBuf *sb, const void *v); | 97 | LJ_FUNC SBuf * LJ_FASTCALL lj_strfmt_putptr(SBuf *sb, const void *v); |
98 | #if LJ_HASJIT | ||
98 | LJ_FUNC SBuf * LJ_FASTCALL lj_strfmt_putquoted(SBuf *sb, GCstr *str); | 99 | LJ_FUNC SBuf * LJ_FASTCALL lj_strfmt_putquoted(SBuf *sb, GCstr *str); |
100 | #endif | ||
99 | 101 | ||
100 | /* Formatted conversions to buffer. */ | 102 | /* Formatted conversions to buffer. */ |
101 | LJ_FUNC SBuf *lj_strfmt_putfxint(SBuf *sb, SFormat sf, uint64_t k); | 103 | LJ_FUNC SBuf *lj_strfmt_putfxint(SBuf *sb, SFormat sf, uint64_t k); |
@@ -103,7 +105,10 @@ LJ_FUNC SBuf *lj_strfmt_putfnum_int(SBuf *sb, SFormat sf, lua_Number n); | |||
103 | LJ_FUNC SBuf *lj_strfmt_putfnum_uint(SBuf *sb, SFormat sf, lua_Number n); | 105 | LJ_FUNC SBuf *lj_strfmt_putfnum_uint(SBuf *sb, SFormat sf, lua_Number n); |
104 | LJ_FUNC SBuf *lj_strfmt_putfnum(SBuf *sb, SFormat, lua_Number n); | 106 | LJ_FUNC SBuf *lj_strfmt_putfnum(SBuf *sb, SFormat, lua_Number n); |
105 | LJ_FUNC SBuf *lj_strfmt_putfchar(SBuf *sb, SFormat, int32_t c); | 107 | LJ_FUNC SBuf *lj_strfmt_putfchar(SBuf *sb, SFormat, int32_t c); |
108 | #if LJ_HASJIT | ||
106 | LJ_FUNC SBuf *lj_strfmt_putfstr(SBuf *sb, SFormat, GCstr *str); | 109 | LJ_FUNC SBuf *lj_strfmt_putfstr(SBuf *sb, SFormat, GCstr *str); |
110 | #endif | ||
111 | LJ_FUNC int lj_strfmt_putarg(lua_State *L, SBuf *sb, int arg, int retry); | ||
107 | 112 | ||
108 | /* Conversions to strings. */ | 113 | /* Conversions to strings. */ |
109 | LJ_FUNC GCstr * LJ_FASTCALL lj_strfmt_int(lua_State *L, int32_t k); | 114 | LJ_FUNC GCstr * LJ_FASTCALL lj_strfmt_int(lua_State *L, int32_t k); |