| 2989 | DISABLE_WARNING_UNREACHABLE_CODE |
| 2990 | |
| 2991 | staticfn int |
| 2992 | nhl_panic(lua_State *L) |
| 2993 | { |
| 2994 | const char *msg = lua_tostring(L, -1); |
| 2995 | |
| 2996 | if (msg == NULL) |
| 2997 | msg = "error object is not a string"; |
| 2998 | panic("unprotected error in call to Lua API (%s)\n", msg); |
| 2999 | /*NOTREACHED*/ |
| 3000 | return 0; /* return to Lua to abort */ |
| 3001 | } |
| 3002 | |
| 3003 | RESTORE_WARNING_UNREACHABLE_CODE |
| 3004 |