diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2013-05-06 14:21:28 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2013-05-06 14:21:28 -0300 |
commit | 2b1c2c61b025aa06446367965316b3878578a768 (patch) | |
tree | cf74b8dd6486eea0d43ea1b61b54d03f47ae4996 | |
parent | fa6ea831b36cbef0acf1595c9b9eec6171792715 (diff) | |
download | lua-2b1c2c61b025aa06446367965316b3878578a768.tar.gz lua-2b1c2c61b025aa06446367965316b3878578a768.tar.bz2 lua-2b1c2c61b025aa06446367965316b3878578a768.zip |
bug: Wrong assert when reporting concatenation errors.
-rw-r--r-- | bugs | 27 |
1 files changed, 25 insertions, 2 deletions
@@ -1880,8 +1880,8 @@ patch = [[ | |||
1880 | +++ lundump.c 2008/04/04 19:51:41 2.7.1.4 | 1880 | +++ lundump.c 2008/04/04 19:51:41 2.7.1.4 |
1881 | @@ -1,5 +1,5 @@ | 1881 | @@ -1,5 +1,5 @@ |
1882 | /* | 1882 | /* |
1883 | -** $Id: bugs,v 1.120 2013/02/07 15:57:47 roberto Exp roberto $ | 1883 | -** $Id: bugs,v 1.121 2013/05/02 16:13:27 roberto Exp roberto $ |
1884 | +** $Id: bugs,v 1.120 2013/02/07 15:57:47 roberto Exp roberto $ | 1884 | +** $Id: bugs,v 1.121 2013/05/02 16:13:27 roberto Exp roberto $ |
1885 | ** load precompiled Lua chunks | 1885 | ** load precompiled Lua chunks |
1886 | ** See Copyright Notice in lua.h | 1886 | ** See Copyright Notice in lua.h |
1887 | */ | 1887 | */ |
@@ -2917,6 +2917,29 @@ patch = [[ | |||
2917 | ]] | 2917 | ]] |
2918 | } | 2918 | } |
2919 | 2919 | ||
2920 | Bug{ | ||
2921 | what = [[Wrong assert when reporting concatenation errors | ||
2922 | (manifests only when Lua is compiled in debug mode)]], | ||
2923 | report = [[Roberto, 2013/05/05]], | ||
2924 | since = [[?]], | ||
2925 | fix = nil, | ||
2926 | example = [[ | ||
2927 | -- only with Lua compiled in debug mode | ||
2928 | print({} .. 2) | ||
2929 | ]], | ||
2930 | patch = [[ | ||
2931 | --- ldebug.c 2013/04/12 18:48:47 2.90.1.1 | ||
2932 | +++ ldebug.c 2013/05/05 14:38:30 | ||
2933 | @@ -519,5 +519,5 @@ | ||
2934 | l_noret luaG_concaterror (lua_State *L, StkId p1, StkId p2) { | ||
2935 | if (ttisstring(p1) || ttisnumber(p1)) p1 = p2; | ||
2936 | - lua_assert(!ttisstring(p1) && !ttisnumber(p2)); | ||
2937 | + lua_assert(!ttisstring(p1) && !ttisnumber(p1)); | ||
2938 | luaG_typeerror(L, p1, "concatenate"); | ||
2939 | } | ||
2940 | ]] | ||
2941 | } | ||
2942 | |||
2920 | --[=[ | 2943 | --[=[ |
2921 | Bug{ | 2944 | Bug{ |
2922 | what = [[ ]], | 2945 | what = [[ ]], |