diff options
author | Leon <github@adigitoleo.dissimulo.com> | 2022-01-14 00:40:27 +1100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-13 14:40:27 +0100 |
commit | a9135095f02587430b179a33ae03910d0d4201cd (patch) | |
tree | c06525ef6678349f58b19d3a2a04a82a74e0255b | |
parent | ada815e45957e5675a9ac978b85b8467d68c5945 (diff) | |
download | Nim-a9135095f02587430b179a33ae03910d0d4201cd.tar.gz |
docs: Mention `import foo {.all.}` syntax (#19377)
Mention the `import foo {.all.}` syntax in the manual, with a caveat about private imports. Also link to the experimental importutils module. Co-authored-by: adigitoleo <adigitoleo@dissimulo.com>
-rw-r--r-- | doc/manual_experimental.rst | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/doc/manual_experimental.rst b/doc/manual_experimental.rst index 4ed8439df..0f82b9950 100644 --- a/doc/manual_experimental.rst +++ b/doc/manual_experimental.rst @@ -168,6 +168,17 @@ This feature will likely be superseded in the future by support for recursive module dependencies. +Importing private symbols +========================= + +In some situations, it may be useful to import all symbols (public or private) +from a module. The syntax `import foo {.all.}` can be used to import all +symbols from the module `foo`. Note that importing private symbols is +generally not recommended. + +See also the experimental `importutils <importutils.html>`_ module. + + Code reordering =============== |