aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorChris Boesch <chrboesch@noreply.codeberg.org>2023-10-05 19:37:53 +0000
committerChris Boesch <chrboesch@noreply.codeberg.org>2023-10-05 19:37:53 +0000
commit6079b0122a89708c0c3853dbdce1e8aef05ebfcc (patch)
tree2f3536c5eab4e1fd0ea87a01f8657c0ee97027a6
parent1c7e35e193de241a80bdf020ae078083b64c4998 (diff)
parente6e78d3f8027eaaf5a1fb8c6e7a364ba045199b0 (diff)
Merge pull request 'fixed broken patch 103' (#9) from fix_patches into main
Reviewed-on: https://codeberg.org/ziglings/exercises/pulls/9
-rw-r--r--patches/patches/103_tokenization.patch15
1 files changed, 12 insertions, 3 deletions
diff --git a/patches/patches/103_tokenization.patch b/patches/patches/103_tokenization.patch
index 98f645b..5fab36d 100644
--- a/patches/patches/103_tokenization.patch
+++ b/patches/patches/103_tokenization.patch
@@ -1,10 +1,19 @@
---- exercises/103_tokenization.zig 2023-10-03 22:15:22.125574535 +0200
-+++ answers/103_tokenization.zig 2023-10-05 20:04:07.309438291 +0200
+--- exercises/103_tokenization.zig 2023-10-05 21:29:56.965283604 +0200
++++ answers/103_tokenization.zig 2023-10-05 21:30:19.815708910 +0200
+@@ -62,7 +62,7 @@
+ // // A standard tokenizer is called (Zig has several) and
+ // // used to locate the positions of the respective separators
+ // // (we remember, space and comma) and pass them to an iterator.
+-// var it = std.mem.tokenizeAny(u8, input, " ,");
++// var it = std.mem.tokenize(u8, input, " ,");
+ //
+ // // The iterator can now be processed in a loop and the
+ // // individual numbers can be transferred.
@@ -136,7 +136,7 @@
;
// now the tokenizer, but what do we need here?
-- var it = std.mem.tokenize(u8, poem, ???);
+- var it = std.mem.tokenizeAny(u8, poem, ???);
+ var it = std.mem.tokenize(u8, poem, " ,;!\n");
// print all words and count them