mirror of
https://github.com/nim-lang/Nim.git
synced 2026-07-31 04:29:02 +00:00
make more standard libraries work with nimPreviewSlimSystem (#20343)
* make more standard libraries work with `nimPreviewSlimSystem` * typo * part two * Delete specutils.nim * fixes more tests * more fixes * fixes tests * fixes three more tests * add formatfloat import * fix * last
This commit is contained in:
@@ -3,6 +3,9 @@
|
||||
when not defined(js):
|
||||
{.fatal: "Module jsbigints is designed to be used with the JavaScript backend.".}
|
||||
|
||||
when defined(nimPreviewSlimSystem):
|
||||
import std/assertions
|
||||
|
||||
type JsBigIntImpl {.importjs: "bigint".} = int # https://github.com/nim-lang/Nim/pull/16606
|
||||
type JsBigInt* = distinct JsBigIntImpl ## Arbitrary precision integer for JavaScript target.
|
||||
|
||||
|
||||
@@ -62,6 +62,9 @@ when not defined(js):
|
||||
when defined(posix):
|
||||
import posix
|
||||
|
||||
when defined(nimPreviewSlimSystem):
|
||||
import std/assertions
|
||||
|
||||
const
|
||||
batchImplOS = defined(freebsd) or defined(openbsd) or defined(zephyr) or (defined(macosx) and not defined(ios))
|
||||
batchSize {.used.} = 256
|
||||
|
||||
@@ -13,6 +13,9 @@
|
||||
import std/[macros, isolation, typetraits]
|
||||
import system/ansi_c
|
||||
|
||||
when defined(nimPreviewSlimSystem):
|
||||
import std/assertions
|
||||
|
||||
export isolation
|
||||
|
||||
|
||||
|
||||
@@ -19,6 +19,8 @@ See also:
|
||||
|
||||
import os, random
|
||||
|
||||
when defined(nimPreviewSlimSystem):
|
||||
import std/syncio
|
||||
|
||||
const
|
||||
maxRetry = 10000
|
||||
|
||||
Reference in New Issue
Block a user