diff --git a/changelog.md b/changelog.md index 4d24d73c0..fe478f49a 100644 --- a/changelog.md +++ b/changelog.md @@ -38,6 +38,9 @@ - `PInt32`, `PInt64`, `PFloat32`, `PFloat64`, aliases to `ptr int32`, `ptr int64`, `ptr float32`, `ptr float64` +- Enabling `-d:nimPreviewSlimSystem` removes the import of `channels_builtin` in + in the `system` module. + - The `gc:v2` option is removed. - The `mainmodule` and `m` options are removed. diff --git a/doc/lib.md b/doc/lib.md index 468ee84e3..082437ebc 100644 --- a/doc/lib.md +++ b/doc/lib.md @@ -41,10 +41,6 @@ Automatic imports Basic Nim thread support. **Note:** This is part of the system module. Do not import it explicitly. Enabled with `--threads:on`:option:. -* [channels_builtin](channels_builtin.html) - Nim message passing support for threads. **Note:** This is part of the - system module. Do not import it explicitly. Enabled with `--threads:on`:option:. - Core ---- diff --git a/lib/impure/rdstdin.nim b/lib/impure/rdstdin.nim index adc0e212d..f23657fa9 100644 --- a/lib/impure/rdstdin.nim +++ b/lib/impure/rdstdin.nim @@ -22,6 +22,9 @@ runnableExamples("-r:off"): if line.len > 0: echo line echo "exiting" +when defined(nimPreviewSlimSystem): + import std/syncio + when defined(windows): proc readLineFromStdin*(prompt: string): string {. tags: [ReadIOEffect, WriteIOEffect].} = diff --git a/lib/pure/collections/deques.nim b/lib/pure/collections/deques.nim index c4eb5331e..7e9ed32f3 100644 --- a/lib/pure/collections/deques.nim +++ b/lib/pure/collections/deques.nim @@ -47,7 +47,6 @@ runnableExamples: ## See also ## ======== ## * `lists module `_ for singly and doubly linked lists and rings -## * `channels module `_ for inter-thread communication import std/private/since diff --git a/lib/pure/concurrency/threadpool.nim b/lib/pure/concurrency/threadpool.nim index 50f3be1ea..e17fc38b7 100644 --- a/lib/pure/concurrency/threadpool.nim +++ b/lib/pure/concurrency/threadpool.nim @@ -14,7 +14,6 @@ ## See also ## ======== ## * `threads module `_ for basic thread support -## * `channels module `_ for message passing support ## * `locks module `_ for locks and condition variables ## * `asyncdispatch module `_ for asynchronous IO diff --git a/lib/system.nim b/lib/system.nim index 68645cea0..95ba23a11 100644 --- a/lib/system.nim +++ b/lib/system.nim @@ -2206,7 +2206,8 @@ when notJSnotNims and hasAlloc: include "system/repr" when notJSnotNims and hasThreadSupport and hostOS != "standalone": - include "system/channels_builtin" + when not defined(nimPreviewSlimSystem): + include "system/channels_builtin" when notJSnotNims and hostOS != "standalone": diff --git a/tools/kochdocs.nim b/tools/kochdocs.nim index c0bdb0503..717bac64f 100644 --- a/tools/kochdocs.nim +++ b/tools/kochdocs.nim @@ -137,10 +137,6 @@ niminst.md mm.md """.splitWhitespace().mapIt("doc" / it) - doc0 = """ -lib/system/channels_builtin.nim -""".splitWhitespace() # ran by `nim doc0` instead of `nim doc` - withoutIndex = """ lib/wrappers/mysql.nim lib/wrappers/sqlite3.nim @@ -185,7 +181,6 @@ when (NimMajor, NimMinor) < (1, 1) or not declared(isRelativeTo): proc getDocList(): seq[string] = var docIgnore: HashSet[string] - for a in doc0: docIgnore.incl a for a in withoutIndex: docIgnore.incl a for a in ignoredModules: docIgnore.incl a @@ -260,7 +255,7 @@ proc buildDoc(nimArgs, destPath: string) = # call nim for the documentation: let rst2html = getMd2html() var - commands = newSeq[string](rst2html.len + len(doc0) + len(doc) + withoutIndex.len) + commands = newSeq[string](rst2html.len + len(doc) + withoutIndex.len) i = 0 let nim = findNim().quoteShell() for d in items(rst2html): @@ -268,11 +263,6 @@ proc buildDoc(nimArgs, destPath: string) = [nimArgs, gitUrl, destPath / changeFileExt(splitFile(d).name, "html"), d] i.inc - for d in items(doc0): - commands[i] = nim & " doc0 $# --git.url:$# -o:$# --index:on $#" % - [nimArgs, gitUrl, - destPath / changeFileExt(splitFile(d).name, "html"), d] - i.inc for d in items(doc): let extra = if isJsOnly(d): "--backend:js" else: "" var nimArgs2 = nimArgs