aboutsummaryrefslogtreecommitdiff
path: root/lobject.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2022-09-23 11:08:10 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2022-09-23 11:08:10 -0300
commit26be27459b11feabed52cf40aaa76f86c7edc977 (patch)
tree9f3cd8be898991a52f6b5f8b140a12b8b9acb51d /lobject.c
parentcfbe378f906061ee56f91acfbdf569d0d3fb9556 (diff)
downloadlua-26be27459b11feabed52cf40aaa76f86c7edc977.tar.gz
lua-26be27459b11feabed52cf40aaa76f86c7edc977.tar.bz2
lua-26be27459b11feabed52cf40aaa76f86c7edc977.zip
Negation in constant folding of '>>' may overflow
Diffstat (limited to 'lobject.c')
-rw-r--r--lobject.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lobject.c b/lobject.c
index a2c00609..03e2798c 100644
--- a/lobject.c
+++ b/lobject.c
@@ -62,7 +62,7 @@ static lua_Integer intarith (lua_State *L, int op, lua_Integer v1,
62 case LUA_OPBOR: return intop(|, v1, v2); 62 case LUA_OPBOR: return intop(|, v1, v2);
63 case LUA_OPBXOR: return intop(^, v1, v2); 63 case LUA_OPBXOR: return intop(^, v1, v2);
64 case LUA_OPSHL: return luaV_shiftl(v1, v2); 64 case LUA_OPSHL: return luaV_shiftl(v1, v2);
65 case LUA_OPSHR: return luaV_shiftl(v1, -v2); 65 case LUA_OPSHR: return luaV_shiftr(v1, v2);
66 case LUA_OPUNM: return intop(-, 0, v1); 66 case LUA_OPUNM: return intop(-, 0, v1);
67 case LUA_OPBNOT: return intop(^, ~l_castS2U(0), v1); 67 case LUA_OPBNOT: return intop(^, ~l_castS2U(0), v1);
68 default: lua_assert(0); return 0; 68 default: lua_assert(0); return 0;