mirror of
https://github.com/nim-lang/Nim.git
synced 2026-04-19 05:50:30 +00:00
Update 'compiles' documentation to remove not (#5666)
Documentation for proc compiles showed a broken/unintuitive example (unless i missed something)
This commit is contained in:
committed by
Andreas Rumpf
parent
88c4d6aabe
commit
4ba6f9808e
@@ -3663,7 +3663,7 @@ proc compiles*(x: untyped): bool {.magic: "Compiles", noSideEffect, compileTime.
|
||||
## This can be used to check whether a type supports some operation:
|
||||
##
|
||||
## .. code-block:: Nim
|
||||
## when not compiles(3 + 4):
|
||||
## when compiles(3 + 4):
|
||||
## echo "'+' for integers is available"
|
||||
discard
|
||||
|
||||
|
||||
Reference in New Issue
Block a user