From d6229f20ffce969a48b100d45e4b3b165af2ce72 Mon Sep 17 00:00:00 2001 From: Ico Doornekamp Date: Fri, 23 Feb 2018 19:16:11 +0100 Subject: Allow float argument to sleepAsync() to allow sub-millisecond resolution --- lib/pure/asyncdispatch.nim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/pure/asyncdispatch.nim b/lib/pure/asyncdispatch.nim index a52c667fc..dfc7201b8 100644 --- a/lib/pure/asyncdispatch.nim +++ b/lib/pure/asyncdispatch.nim @@ -1513,7 +1513,7 @@ proc poll*(timeout = 500) = # Common procedures between current and upcoming asyncdispatch include includes.asynccommon -proc sleepAsync*(ms: int): Future[void] = +proc sleepAsync*(ms: int | float): Future[void] = ## Suspends the execution of the current async procedure for the next ## ``ms`` milliseconds. var retFuture = newFuture[void]("sleepAsync") -- cgit 1.4.1-2-gfad0