aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2017-09-26 14:10:49 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2017-09-26 14:10:49 -0300
commit13256a4173af4004518d65211b4bf1aebcd5fc25 (patch)
tree226160a5e42a38b2f5888dc62f9472042bc7edf3
parentabb17cf19bf7328a394f1758542172c4b4dbb539 (diff)
downloadlua-13256a4173af4004518d65211b4bf1aebcd5fc25.tar.gz
lua-13256a4173af4004518d65211b4bf1aebcd5fc25.tar.bz2
lua-13256a4173af4004518d65211b4bf1aebcd5fc25.zip
detail
put explicit all cases for a switch of an enumeration
-rw-r--r--lcode.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/lcode.c b/lcode.c
index f7bc2140..0fcde154 100644
--- a/lcode.c
+++ b/lcode.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lcode.c,v 2.122 2017/09/13 19:50:08 roberto Exp roberto $ 2** $Id: lcode.c,v 2.123 2017/09/19 18:38:14 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*/
@@ -1263,10 +1263,12 @@ void luaK_infix (FuncState *fs, BinOpr op, expdesc *v) {
1263 /* else keep numeral, which may be folded with 2nd operand */ 1263 /* else keep numeral, which may be folded with 2nd operand */
1264 break; 1264 break;
1265 } 1265 }
1266 default: { 1266 case OPR_EQ: case OPR_LT: case OPR_LE:
1267 case OPR_NE: case OPR_GT: case OPR_GE: {
1267 luaK_exp2RK(fs, v); 1268 luaK_exp2RK(fs, v);
1268 break; 1269 break;
1269 } 1270 }
1271 default: lua_assert(0);
1270 } 1272 }
1271} 1273}
1272 1274