** Checks whether a float has a value representable as a lua_Integer ** (and does the conversion if so) */
| 89 | ** (and does the conversion if so) |
| 90 | */ |
| 91 | static int numisinteger (lua_Number x, lua_Integer *p) { |
| 92 | if ((x) == l_floor(x)) /* integral value? */ |
| 93 | return lua_numbertointeger(x, p); /* try as an integer */ |
| 94 | else return 0; |
| 95 | } |
| 96 | |
| 97 | |
| 98 | /* |
no outgoing calls
no test coverage detected