diff --git a/asyncdispatch2/timer.nim b/asyncdispatch2/timer.nim index 3b0e228..ff1c4b5 100644 --- a/asyncdispatch2/timer.nim +++ b/asyncdispatch2/timer.nim @@ -22,8 +22,11 @@ when defined(windows): elif defined(macosx): - from posix import posix_gettimeofday, Timeval + from posix import Timeval + proc posix_gettimeofday(tp: var Timeval, unused: pointer = nil) {. + importc: "gettimeofday", header: "".} + proc fastEpochTime*(): uint64 {.inline.} = var t: Timeval posix_gettimeofday(t)