diff options
author | Andreas Rumpf <rumpf_a@web.de> | 2018-04-28 09:31:22 +0200 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2018-04-28 09:31:22 +0200 |
commit | 1eaeb8945b880ee90482bc399e2dbb320a98cd93 (patch) | |
tree | e9b211a288e5117fdacb9a07a7a3554c842daaec /lib | |
parent | ee7515e376da88df2261fdb014ee5075919a7012 (diff) | |
download | Nim-1eaeb8945b880ee90482bc399e2dbb320a98cd93.tar.gz |
system.nim documentation: setLen can handle nil now
Diffstat (limited to 'lib')
-rw-r--r-- | lib/system.nim | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/system.nim b/lib/system.nim index 98c133428..523a25d64 100644 --- a/lib/system.nim +++ b/lib/system.nim @@ -1280,15 +1280,13 @@ proc setLen*[T](s: var seq[T], newlen: Natural) {. ## sets the length of `s` to `newlen`. ## ``T`` may be any sequence type. ## If the current length is greater than the new length, - ## ``s`` will be truncated. `s` cannot be nil! To initialize a sequence with - ## a size, use ``newSeq`` instead. + ## ``s`` will be truncated. proc setLen*(s: var string, newlen: Natural) {. magic: "SetLengthStr", noSideEffect.} ## sets the length of `s` to `newlen`. ## If the current length is greater than the new length, - ## ``s`` will be truncated. `s` cannot be nil! To initialize a string with - ## a size, use ``newString`` instead. + ## ``s`` will be truncated. ## ## .. code-block:: Nim ## var myS = "Nim is great!!" |