better docs: strutils
This commit is contained in:
parent
b097081f10
commit
be6456f0f4
2 changed files with 1383 additions and 886 deletions
File diff suppressed because it is too large
Load diff
|
|
@ -2,10 +2,6 @@ discard """
|
||||||
cmd: "nim check $file"
|
cmd: "nim check $file"
|
||||||
errormsg: "type mismatch: got <string, set[char], maxsplits: int literal(1)>"
|
errormsg: "type mismatch: got <string, set[char], maxsplits: int literal(1)>"
|
||||||
nimout: '''
|
nimout: '''
|
||||||
proc rsplit(s: string; sep: string; maxsplit: int = -1): seq[string]
|
|
||||||
first type mismatch at position: 2
|
|
||||||
required type: string
|
|
||||||
but expression '{':'}' is of type: set[char]
|
|
||||||
proc rsplit(s: string; sep: char; maxsplit: int = -1): seq[string]
|
proc rsplit(s: string; sep: char; maxsplit: int = -1): seq[string]
|
||||||
first type mismatch at position: 2
|
first type mismatch at position: 2
|
||||||
required type: char
|
required type: char
|
||||||
|
|
@ -13,6 +9,10 @@ proc rsplit(s: string; sep: char; maxsplit: int = -1): seq[string]
|
||||||
proc rsplit(s: string; seps: set[char] = Whitespace; maxsplit: int = -1): seq[string]
|
proc rsplit(s: string; seps: set[char] = Whitespace; maxsplit: int = -1): seq[string]
|
||||||
first type mismatch at position: 3
|
first type mismatch at position: 3
|
||||||
unknown named parameter: maxsplits
|
unknown named parameter: maxsplits
|
||||||
|
proc rsplit(s: string; sep: string; maxsplit: int = -1): seq[string]
|
||||||
|
first type mismatch at position: 2
|
||||||
|
required type: string
|
||||||
|
but expression '{':'}' is of type: set[char]
|
||||||
|
|
||||||
expression: rsplit("abc:def", {':'}, maxsplits = 1)
|
expression: rsplit("abc:def", {':'}, maxsplits = 1)
|
||||||
'''
|
'''
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue