allow random module to be used in standalone: (#12617)

proc randomized*() uses time releated function which is not available on
standalone, so disable this function for standalone.
This commit is contained in:
Judd
2019-11-07 21:48:33 +08:00
committed by Andreas Rumpf
parent e1b1759439
commit 8b1ef8e07e

View File

@@ -625,7 +625,7 @@ proc shuffle*[T](x: var openArray[T]) =
doAssert cards == ["King", "Ace", "Queen", "Ten", "Jack"]
shuffle(state, x)
when not defined(nimscript):
when not defined(nimscript) and not defined(standalone):
import times
proc randomize*() {.benign.} =