diff options
author | Andreas Rumpf <rumpf_a@web.de> | 2019-06-08 00:13:57 +0200 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2019-06-08 00:13:57 +0200 |
commit | bf63d83a9759b6764a0b78b424f4635af35d743f (patch) | |
tree | 738c563d0bd0a02323c687d8610c31b2ef1126fd /doc/nimc.rst | |
parent | 9f82e07b2dc2ea89e1e35d5ec470fae84eab66b4 (diff) | |
download | Nim-bf63d83a9759b6764a0b78b424f4635af35d743f.tar.gz |
update the nimc.rst document about the release/danger split [bugfix]
Diffstat (limited to 'doc/nimc.rst')
-rw-r--r-- | doc/nimc.rst | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/doc/nimc.rst b/doc/nimc.rst index d291992ff..4f5808cd2 100644 --- a/doc/nimc.rst +++ b/doc/nimc.rst @@ -132,8 +132,8 @@ Through the ``-d:x`` or ``--define:x`` switch you can define compile time symbols for conditional compilation. The defined switches can be checked in source code with the `when statement <manual.html#when-statement>`_ and `defined proc <system.html#defined>`_. The typical use of this switch is to -enable builds in release mode (``-d:release``) where certain safety checks are -omitted for better performance. Another common use is the ``-d:ssl`` switch to +enable builds in release mode (``-d:release``) where optimizations are +enabled for better performance. Another common use is the ``-d:ssl`` switch to activate SSL sockets. Additionally, you may pass a value along with the symbol: ``-d:x=y`` @@ -169,6 +169,10 @@ The default build of a project is a `debug build`:idx:. To compile a nim c -d:release myproject.nim + To compile a `dangerous release build`:idx: define the ``danger`` symbol:: + + nim c -d:danger myproject.nim + Search path handling -------------------- @@ -344,10 +348,10 @@ complete list. ====================== ========================================================= Define Effect ====================== ========================================================= -``release`` Turns off runtime checks and turns on the optimizer. +``release`` Turns on the optimizer. More aggressive optimizations are possible, eg: ``--passC:-ffast-math`` (but see issue #10305) - ``--stacktrace:off`` +``danger`` Turns off all runtime checks and turns on the optimizer. ``useFork`` Makes ``osproc`` use ``fork`` instead of ``posix_spawn``. ``useNimRtl`` Compile and link against ``nimrtl.dll``. ``useMalloc`` Makes Nim use C's `malloc`:idx: instead of Nim's |