aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordaurnimator <quae@daurnimator.com>2017-09-03 17:57:43 +1000
committerdaurnimator <quae@daurnimator.com>2017-09-03 17:57:43 +1000
commita3f456ad999c7ec317fdf71d61cbcd80db74d0fe (patch)
tree8e0ae13659b8f058fbdabfcef0219df48fd40f70
parent6f3deeaa6a4743e1f5148c613addb3f94a22d2df (diff)
downloadlua-compat-5.3-a3f456ad999c7ec317fdf71d61cbcd80db74d0fe.tar.gz
lua-compat-5.3-a3f456ad999c7ec317fdf71d61cbcd80db74d0fe.tar.bz2
lua-compat-5.3-a3f456ad999c7ec317fdf71d61cbcd80db74d0fe.zip
Use FALLTHROUGH annotation to fix -Wimplicit-fallthrough warning
Using a form that passes -Wimplicit-fallthrough=4. See https://gcc.gnu.org/onlinedocs/gcc-7.1.0/gcc/Warning-Options.html#index-Wimplicit-fallthrough
-rw-r--r--c-api/compat-5.3.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/c-api/compat-5.3.c b/c-api/compat-5.3.c
index 883efb8..fab89c0 100644
--- a/c-api/compat-5.3.c
+++ b/c-api/compat-5.3.c
@@ -110,7 +110,7 @@ COMPAT53_API void lua_len (lua_State *L, int i) {
110 case LUA_TUSERDATA: 110 case LUA_TUSERDATA:
111 if (luaL_callmeta(L, i, "__len")) 111 if (luaL_callmeta(L, i, "__len"))
112 break; 112 break;
113 /* maybe fall through */ 113 /* FALLTHROUGH */
114 default: 114 default:
115 luaL_error(L, "attempt to get length of a %s value", 115 luaL_error(L, "attempt to get length of a %s value",
116 lua_typename(L, lua_type(L, i))); 116 lua_typename(L, lua_type(L, i)));