| 111 | } |
| 112 | |
| 113 | void xs_timer_schedule(xsMachine *the) |
| 114 | { |
| 115 | int argc = xsmcArgc; |
| 116 | modTimer timer = xsmcGetHostDataValidate(xsArg(0), (void *)&modTimerHooks); |
| 117 | |
| 118 | if (1 == argc) |
| 119 | modTimerUnschedule(timer); |
| 120 | else { |
| 121 | int interval = xsmcToInteger(xsArg(1)); |
| 122 | int repeat = (argc > 2) ? xsmcToInteger(xsArg(2)) : 0; |
| 123 | modTimerReschedule(timer, interval, repeat); |
| 124 | } |
| 125 | } |
| 126 | |
| 127 | void xs_timer_clear(xsMachine *the) |
| 128 | { |
nothing calls this directly
no test coverage detected