Brendan Hansknecht
48f17a8e2c
add Str.releaseExcessCapacity
2023-03-15 15:24:59 -07:00
Luke Boswell
2241b173bf
return markdown headings to preserve structure
2023-03-15 18:30:44 +11:00
Luke Boswell
91604f8be6
return structure using <h2> elements, fix css
2023-03-15 18:19:33 +11:00
Luke Boswell
d2bb434092
roc format
2023-03-14 18:36:12 +11:00
Luke Boswell
213111ca55
minor doc fixes, add docs for Set
2023-03-14 18:33:59 +11:00
Luke Boswell
890f3db10a
update to support fenced code
2023-03-08 17:30:30 +11:00
Luke Boswell
5ead576976
fix indentation for code blocks
2023-03-06 22:32:25 +11:00
David Dunn
550b22c633
Fix unicode escape sequences in Str docs
...
Unicode characters are escaped like \u(00) instead of \{0x00}. Tested
that this is the same for the repl and the hello world example
`Stdout.line "Hello,\u(0A)World!"`.
Found the correct syntax here:
304768569
2023-01-31 21:39:57 +04:00
Richard Feldman
8606faa9db
Move builtin module-level docs to the top
2022-12-26 23:57:27 -05:00
Richard Feldman
2fd968e023
Fix Str.fromUtf8 type annotation
2022-11-14 12:02:33 -05:00
Richard Feldman
e6808b3252
Delete some redundant Str docs
2022-11-14 11:58:09 -05:00
Richard Feldman
4a1196a2bf
Use present tense more in Str docs
2022-11-14 11:38:33 -05:00
Richard Feldman
477dda3cc6
Use expect
more in Str docs
2022-11-14 11:36:54 -05:00
Richard Feldman
3f8829e310
Linkify a list mention in Str docs
2022-11-14 11:34:24 -05:00
Richard Feldman
d814ed3c27
Link to Bool.true and Bool.false in docs
2022-11-14 11:33:32 -05:00
Richard Feldman
c23e23abf5
Fix some Str docs
2022-11-14 11:33:17 -05:00
Richard Feldman
d9774109f1
Merge remote-tracking branch 'origin/main' into str-docs
2022-11-14 11:30:31 -05:00
Richard Feldman
8a47ebd22e
Some more Str docs changes
2022-11-14 09:42:59 -05:00
Ayaz Hafiz
cfe7c8e5ef
Warn on the presence of unnecessary wildcards in output positions
2022-10-31 09:38:20 -05:00
Prajwal S N
df7e4eea7e
builtin(str): implement Str.graphemes
...
Signed-off-by: Prajwal S N <prajwalnadig21@gmail.com>
2022-10-22 19:29:49 -07:00
Anton-4
78e66c6c26
format Str.roc
2022-10-15 11:19:54 +02:00
Anton-4
762bd43e5f
minor improvements
...
Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com>
2022-10-15 09:46:41 +02:00
Anton-4
789586f545
add link with explanation of grapheme
...
Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com>
2022-10-15 09:17:08 +02:00
Luke Boswell
e1e084a68d
remove >>> from comments
2022-10-15 16:29:42 +11:00
Luke Boswell
1b4e89203d
updated Str builtin documentation
2022-10-15 16:15:43 +11:00
Luke Boswell
0b1365e0a3
adding expect and documentation for Str builtin
2022-10-14 19:58:07 +11:00
Ayaz Hafiz
a256947a9f
Move Eq to Bool
2022-10-12 16:37:51 -05:00
Ayaz Hafiz
c618ced743
Replace Bool.isEq
with Eq.isEq
2022-10-12 16:37:49 -05:00
Brendan Hansknecht
96b5d365b2
Add capacity growth to RocStr
...
Also, cleans up the alloc and realloc api for both list and str.
Updates Str.reserve to match List.reserve
2022-10-10 22:24:55 -07:00
Prajwal S N
aef15ac1e8
Merge branch 'main' into str-withprefix
2022-10-09 15:53:16 +05:30
Prajwal S N
d6526fa425
builtin(str): add withPrefix
...
Closes #4142
Signed-off-by: Prajwal S N <prajwalnadig21@gmail.com>
2022-10-08 12:52:10 +05:30
Prajwal S N
9013e4ce11
builtin(str): implement withCapacity
...
Signed-off-by: Prajwal S N <prajwalnadig21@gmail.com>
2022-10-08 00:24:46 +05:30
Ayaz Hafiz
5416eb7cbf
List dependencies in the stdlib explicitly rather than hard-coding
2022-10-05 18:53:49 -05:00
Jan Van Bruggen
cd5747a15c
Run formatter even though it makes matchesAtHelp
uglier
...
Signed-off-by: Jan Van Bruggen <JanCVanB@pm.me>
2022-09-29 23:28:34 -06:00
Jan Van Bruggen
5d814b3ea5
Refactor matchesAtHelp
for clarity
...
Signed-off-by: Jan Van Bruggen <JanCVanB@pm.me>
2022-09-29 23:28:27 -06:00
Ayaz Hafiz
c9c2f61e3e
Add some docs to matchesAtHelp
2022-09-29 22:32:16 -05:00
Ayaz Hafiz
1d7dc65800
Str.splitFirst should not find match if needle is longer than haystack
...
Closes #4064
2022-09-28 13:14:36 -05:00
kilianv
610c529ba8
Update roc files to use new opaque bools
2022-09-20 14:42:04 -05:00
Richard Feldman
620a3feb75
Add some tests for Str.replace___ functions
2022-09-12 21:05:50 -06:00
Richard Feldman
4ed63c548b
Fix type mismatches in Str.replace___ functions
...
...and fix/finish the draft `Str.replaceEach` implementation!
Don't be so modest, Richard :)
2022-09-12 21:05:38 -06:00
Jan Van Bruggen
9ef57f86ac
Add first draft of Str.replaceEach
builtin
2022-09-12 21:03:11 -06:00
Jan Van Bruggen
2b65659a11
Add Str.replaceLast
builtin
2022-09-12 20:37:23 -06:00
Jan Van Bruggen
c5b6aef21a
Add Str.replaceFirst
builtin
2022-09-12 20:37:23 -06:00
kilianv
97f49bf940
Add expect tests for Str.splitLast
2022-09-01 16:59:11 +02:00
kilianv
d89253779a
Add expect tests for Str.splitFirst
2022-09-01 16:57:19 +02:00
kilianv
23e430d91d
Fix splitFirst bug
...
The reason was an of-by-one error.
2022-09-01 16:48:04 +02:00
Richard Feldman
04fa17144d
Improve a bunch of Str docs
2022-08-28 09:01:17 -04:00
Richard Feldman
807f73fecf
Add some expects to Str
2022-08-06 21:45:21 +02:00
Mostly Void
d6a54710d6
Fix Str.splitLast
...
This fixes the behavior of the function when the needle is positioned
last in the haystack.
» Str.splitLast "ehllo,," ",,"
Ok { after: "", before: "ehllo" } : Result { after : Str, before : Str } [NotFound]*
2022-08-03 11:30:49 +05:30
Brian Carroll
dae8eccb70
Fix a comment in Str.roc
2022-07-16 08:26:19 +01:00