summary refs log tree commit diff stats
path: root/doc
diff options
context:
space:
mode:
authorJuan Carlos <juancarlospaco@gmail.com>2020-06-19 10:08:45 -0300
committerGitHub <noreply@github.com>2020-06-19 15:08:45 +0200
commit99c198625c602984578f9c53b05a28c54de4f4cb (patch)
tree80bb1b5bb5c9ae7f20efca134d251fd72c3e5507 /doc
parent2039e3e883ac42cd9b6012335a92564ca2b56387 (diff)
downloadNim-99c198625c602984578f9c53b05a28c54de4f4cb.tar.gz
Deprecate unroll pragma, remove from documentation (#14705)
Diffstat (limited to 'doc')
-rw-r--r--doc/manual.rst19
1 files changed, 0 insertions, 19 deletions
diff --git a/doc/manual.rst b/doc/manual.rst
index 75cc507a4..a7bca7616 100644
--- a/doc/manual.rst
+++ b/doc/manual.rst
@@ -6210,25 +6210,6 @@ the underlying backend (C compiler) does not support the computed goto
 extension the pragma is simply ignored.
 
 
-unroll pragma
--------------
-The ``unroll`` pragma can be used to tell the compiler that it should unroll
-a `for`:idx: or `while`:idx: loop for execution efficiency:
-
-.. code-block:: nim
-  proc searchChar(s: string, c: char): int =
-    for i in 0 .. s.high:
-      {.unroll: 4.}
-      if s[i] == c: return i
-    result = -1
-
-In the above example, the search loop is unrolled by a factor 4. The unroll
-factor can be left out too; the compiler then chooses an appropriate unroll
-factor.
-
-**Note**: Currently the compiler recognizes but ignores this pragma.
-
-
 immediate pragma
 ----------------