aboutsummaryrefslogtreecommitdiff
path: root/src/lj_api.c
diff options
context:
space:
mode:
authorMike Pall <mike>2013-05-12 23:52:09 +0200
committerMike Pall <mike>2013-05-12 23:52:09 +0200
commit19a9206caf1df71308bd8e4bd61c082026c6811c (patch)
treeff4827d89b46e6b6d0bc4ab90110496d6e8387be /src/lj_api.c
parent7d5acc29181a5194b05fd4650b9e28e4c4978ad1 (diff)
downloadluajit-19a9206caf1df71308bd8e4bd61c082026c6811c.tar.gz
luajit-19a9206caf1df71308bd8e4bd61c082026c6811c.tar.bz2
luajit-19a9206caf1df71308bd8e4bd61c082026c6811c.zip
Refactor internal string formatting.
Diffstat (limited to 'src/lj_api.c')
-rw-r--r--src/lj_api.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/lj_api.c b/src/lj_api.c
index edb2d620..451e4444 100644
--- a/src/lj_api.c
+++ b/src/lj_api.c
@@ -24,6 +24,7 @@
24#include "lj_trace.h" 24#include "lj_trace.h"
25#include "lj_vm.h" 25#include "lj_vm.h"
26#include "lj_strscan.h" 26#include "lj_strscan.h"
27#include "lj_strfmt.h"
27 28
28/* -- Common helper functions --------------------------------------------- */ 29/* -- Common helper functions --------------------------------------------- */
29 30
@@ -606,7 +607,7 @@ LUA_API const char *lua_pushvfstring(lua_State *L, const char *fmt,
606 va_list argp) 607 va_list argp)
607{ 608{
608 lj_gc_check(L); 609 lj_gc_check(L);
609 return lj_str_pushvf(L, fmt, argp); 610 return lj_strfmt_pushvf(L, fmt, argp);
610} 611}
611 612
612LUA_API const char *lua_pushfstring(lua_State *L, const char *fmt, ...) 613LUA_API const char *lua_pushfstring(lua_State *L, const char *fmt, ...)
@@ -615,7 +616,7 @@ LUA_API const char *lua_pushfstring(lua_State *L, const char *fmt, ...)
615 va_list argp; 616 va_list argp;
616 lj_gc_check(L); 617 lj_gc_check(L);
617 va_start(argp, fmt); 618 va_start(argp, fmt);
618 ret = lj_str_pushvf(L, fmt, argp); 619 ret = lj_strfmt_pushvf(L, fmt, argp);
619 va_end(argp); 620 va_end(argp);
620 return ret; 621 return ret;
621} 622}