MCPcopy Create free account
hub / github.com/DFHack/dfhack / digit

Function digit

depends/lua/src/lstrlib.c:1180–1180  ·  view source on GitHub ↗

** Read an integer numeral from string 'fmt' or return 'df' if ** there is no numeral */

Source from the content-addressed store, hash-verified

1178** there is no numeral
1179*/
1180static int digit (int c) { return '0' <= c && c <= '9'; }
1181
1182static int getnum (const char **fmt, int df) {
1183 if (!digit(**fmt)) /* no number? */

Callers 1

getnumFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected