fixes #1739
This commit is contained in:
parent
b131439a2a
commit
7cf36add37
1 changed files with 9 additions and 3 deletions
|
|
@ -45,13 +45,19 @@ Import statement
|
||||||
~~~~~~~~~~~~~~~~
|
~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
After the ``import`` statement a list of module names can follow or a single
|
After the ``import`` statement a list of module names can follow or a single
|
||||||
module name followed by an ``except`` to prevent some symbols to be imported:
|
module name followed by an ``except`` list to prevent some symbols to be
|
||||||
|
imported:
|
||||||
|
|
||||||
.. code-block:: nim
|
.. code-block:: nim
|
||||||
import strutils except `%`
|
import strutils except `%`, toUpper
|
||||||
|
|
||||||
# doesn't work then:
|
# doesn't work then:
|
||||||
echo "$1" % "abc"
|
echo "$1" % "abc".toUpper
|
||||||
|
|
||||||
|
|
||||||
|
It is not checked that the ``except`` list is really exported from the module.
|
||||||
|
This feature allows to compile against an older version of the module that
|
||||||
|
lacks does not export these identifiers.
|
||||||
|
|
||||||
|
|
||||||
Include statement
|
Include statement
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue