diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2015-09-08 12:41:05 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2015-09-08 12:41:05 -0300 |
commit | 41964648eea1427d53934b886abb68cc8457b019 (patch) | |
tree | b0388dfebe6614d5d49306193faf78f8b9e1a6a1 /ldo.c | |
parent | 502214f8a551cd01d94677f98a40aa51531ef71d (diff) | |
download | lua-41964648eea1427d53934b886abb68cc8457b019.tar.gz lua-41964648eea1427d53934b886abb68cc8457b019.tar.bz2 lua-41964648eea1427d53934b886abb68cc8457b019.zip |
long strings are created directly in final position when possible
(instead of using an auxiliar buffer to first create the string
and then allocate the final string and copy result there)
Diffstat (limited to 'ldo.c')
-rw-r--r-- | ldo.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: ldo.c,v 2.138 2015/05/22 17:48:19 roberto Exp roberto $ | 2 | ** $Id: ldo.c,v 2.139 2015/06/18 14:19:52 roberto Exp roberto $ |
3 | ** Stack and Call structure of Lua | 3 | ** Stack and Call structure of Lua |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -684,7 +684,7 @@ static void f_parser (lua_State *L, void *ud) { | |||
684 | int c = zgetc(p->z); /* read first character */ | 684 | int c = zgetc(p->z); /* read first character */ |
685 | if (c == LUA_SIGNATURE[0]) { | 685 | if (c == LUA_SIGNATURE[0]) { |
686 | checkmode(L, p->mode, "binary"); | 686 | checkmode(L, p->mode, "binary"); |
687 | cl = luaU_undump(L, p->z, &p->buff, p->name); | 687 | cl = luaU_undump(L, p->z, p->name); |
688 | } | 688 | } |
689 | else { | 689 | else { |
690 | checkmode(L, p->mode, "text"); | 690 | checkmode(L, p->mode, "text"); |