summaryrefslogtreecommitdiff
path: root/lstrlib.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2018-12-17 14:46:37 -0200
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2018-12-17 14:46:37 -0200
commit063d4e4543088e7a21965bda8ee5a0f952a9029e (patch)
tree6c3f2f8e98c26f071a94a32f9f2754396a66a9de /lstrlib.c
parente354c6355e7f48e087678ec49e340ca0696725b1 (diff)
downloadlua-5.3.5.tar.gz
lua-5.3.5.tar.bz2
lua-5.3.5.zip
Lua 5.3.5 ported to gitv5.3.5
This is the first commit for the branch Lua 5.3. All source files were copied from the official distribution of 5.3.5 in the Lua site. The test files are the same of 5.3.4. The manual came from the previous RCS repository, revision 1.167.1.2.
Diffstat (limited to '')
-rw-r--r--lstrlib.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/lstrlib.c b/lstrlib.c
index 934b7db8..b4bed7e9 100644
--- a/lstrlib.c
+++ b/lstrlib.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lstrlib.c,v 1.253 2016/12/20 18:37:00 roberto Exp roberto $ 2** $Id: lstrlib.c,v 1.254.1.1 2017/04/19 17:29:57 roberto Exp $
3** Standard library for string operations and pattern-matching 3** Standard library for string operations and pattern-matching
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -879,7 +879,7 @@ static int lua_number2strx (lua_State *L, char *buff, int sz,
879 buff[i] = toupper(uchar(buff[i])); 879 buff[i] = toupper(uchar(buff[i]));
880 } 880 }
881 else if (fmt[SIZELENMOD] != 'a') 881 else if (fmt[SIZELENMOD] != 'a')
882 luaL_error(L, "modifiers for format '%%a'/'%%A' not implemented"); 882 return luaL_error(L, "modifiers for format '%%a'/'%%A' not implemented");
883 return n; 883 return n;
884} 884}
885 885
@@ -1199,8 +1199,8 @@ static int getnum (const char **fmt, int df) {
1199static int getnumlimit (Header *h, const char **fmt, int df) { 1199static int getnumlimit (Header *h, const char **fmt, int df) {
1200 int sz = getnum(fmt, df); 1200 int sz = getnum(fmt, df);
1201 if (sz > MAXINTSIZE || sz <= 0) 1201 if (sz > MAXINTSIZE || sz <= 0)
1202 luaL_error(h->L, "integral size (%d) out of limits [1,%d]", 1202 return luaL_error(h->L, "integral size (%d) out of limits [1,%d]",
1203 sz, MAXINTSIZE); 1203 sz, MAXINTSIZE);
1204 return sz; 1204 return sz;
1205} 1205}
1206 1206