aboutsummaryrefslogtreecommitdiff
path: root/lcode.c
diff options
context:
space:
mode:
Diffstat (limited to 'lcode.c')
-rw-r--r--lcode.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lcode.c b/lcode.c
index 8aa18b49..f53722ff 100644
--- a/lcode.c
+++ b/lcode.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lcode.c,v 2.65 2013/04/25 19:35:19 roberto Exp $ 2** $Id: lcode.c,v 2.66 2013/04/26 13:07:53 roberto Exp roberto $
3** Code generator for Lua 3** Code generator for Lua
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -734,7 +734,7 @@ static int constfolding (OpCode op, expdesc *e1, expdesc *e2) {
734 if (!isnumeral(e1) || !isnumeral(e2)) return 0; 734 if (!isnumeral(e1) || !isnumeral(e2)) return 0;
735 if ((op == OP_DIV || op == OP_IDIV || op == OP_MOD) && e2->u.nval == 0) 735 if ((op == OP_DIV || op == OP_IDIV || op == OP_MOD) && e2->u.nval == 0)
736 return 0; /* do not attempt to divide by 0 */ 736 return 0; /* do not attempt to divide by 0 */
737 r = luaO_arith(op - OP_ADD + LUA_OPADD, e1->u.nval, e2->u.nval); 737 r = luaO_numarith(op - OP_ADD + LUA_OPADD, e1->u.nval, e2->u.nval);
738 e1->u.nval = r; 738 e1->u.nval = r;
739 return 1; 739 return 1;
740} 740}