Commit graph

93 commits

Author SHA1 Message Date
Richard Feldman
ab51582541 Switch builtins to use roc_alloc and friends 2021-05-23 23:46:09 -04:00
Folkert
c071cfba13 implement startsWithCodePoint 2021-05-02 19:26:08 +02:00
Folkert
839095942d reallocate in strings 2021-05-01 23:16:34 +02:00
Folkert
870adb20a8 use decref to deallocate RocStr in zig code 2021-04-14 16:53:36 +02:00
Folkert
134f8a15e9 fix zig tests 2021-02-24 22:26:18 +01:00
Folkert
3537fa57d2 decrement when the input is invalid utf8 2021-02-24 21:46:58 +01:00
Folkert
a6edc58323 make fromUtf8 do RC 2021-02-24 21:25:14 +01:00
Folkert
9116e9e8c9 add Str.toBytes 2021-02-21 19:52:32 +01:00
Folkert
57b78dde06 Merge remote-tracking branch 'origin/trunk' into str-fromUtf8 2021-02-21 15:25:36 +01:00
Folkert
a2a31cb962 reuse allocateWithRefcount in str 2021-02-19 19:26:29 +01:00
Folkert
9473a332db clippy 2021-02-19 19:22:05 +01:00
Folkert
17fddaf0dd refcount details of builtins 2021-02-19 17:13:09 +01:00
Folkert
a37913ff01 fix shadowing 2021-02-16 01:23:10 +01:00
Folkert
411a265024 remove bitcast in Str.fromFloat 2021-02-16 00:56:44 +01:00
Folkert
13b2c23c01 working AStar 2021-02-15 21:34:55 +01:00
Jared Ramirez
2159d94b87 Zig fmt 2021-02-14 19:00:56 -08:00
Jared Ramirez
f3d9c2f2bb Finish first pass of Str.fromUtf8 2021-02-07 20:04:10 -08:00
Jared Ramirez
815f633a58 [WIP] Setup rust side to call Str.fromUtf8 2021-02-07 20:04:10 -08:00
Jared Ramirez
8d73fcda7f Add zig function to check if bytes are valid unicode 2021-02-07 20:01:45 -08:00
Chadtech
a575ff22fa Merge branch 'trunk' of github.com:rtfeldman/roc into dict 2021-02-04 00:37:30 -05:00
Folkert
a79a9ea253 use the compiler's str.zig from platforms 2021-01-31 23:11:02 +01:00
Chadtech
7e63f72922 WIP code for the basic methods on the Zig RocDict type (init, deinit, clone, allocate) 2021-01-31 00:33:06 -05:00
Folkert
dbb1484a91 fix isize/usize mixup 2021-01-26 01:12:46 +01:00
Folkert
712be89c9d fix zig tests 2021-01-25 20:12:37 +01:00
Folkert
205f55be2e cleanup 2021-01-25 17:24:22 +01:00
Folkert
5a62359a5f remove T from join 2021-01-25 17:23:45 +01:00
Folkert
517bde4f4a remove T from concat 2021-01-25 17:22:22 +01:00
Folkert
257985496b use usize to determine size of roc str 2021-01-25 17:13:52 +01:00
Folkert
73de5b8132 joinWith zig implementation and general string improvements 2021-01-25 00:17:41 +01:00
Folkert
18d04614d4 clean up zig str concat 2021-01-21 20:20:20 +01:00
Folkert
2ac19fb6e3 add equality for strings 2021-01-02 18:50:29 +01:00
Folkert
20c041dc60 improvements to str.zig 2020-12-12 01:46:33 +01:00
Jared Ramirez
170b5eb707 Small rename 2020-12-08 17:08:33 -08:00
Jared Ramirez
784f299b43 Various small zig str changes 2020-12-08 17:05:26 -08:00
Jared Ramirez
c39ac471ea Zig format 2020-12-04 14:25:29 -07:00
Jared Ramirez
5697ec209b Fix call to str split; Move some comments around 2020-12-04 14:16:07 -07:00
Jared Ramirez
7e9cf27d94 [WIP] Use zig build system in build script; Nearly fix str tests 2020-12-04 14:07:47 -07:00
Richard Feldman
fc2a37b22b Use alloc over dupe 2020-12-04 01:35:20 -05:00
Richard Feldman
c83e3ce27f Merge branch 'trunk' into no-implicit-zig-allocator 2020-12-04 00:59:23 -05:00
Richard Feldman
ee9f426ed8 Re-camelCase function names 2020-12-04 00:38:33 -05:00
Richard Feldman
0b16f5c1ea Revert "Use camelCase in str.zig"
This reverts commit 0583cc1a27.
2020-12-04 00:38:33 -05:00
Richard Feldman
497e1538b0 fix some memory leaks in tests 2020-12-04 00:29:47 -05:00
Richard Feldman
505ade3282 Don't try to free empty strings 2020-12-04 00:17:46 -05:00
Richard Feldman
ef258fe675 deinit more in tests 2020-12-04 00:05:07 -05:00
Richard Feldman
f55af7282c Merge branch 'trunk' into no-implicit-zig-allocator 2020-12-03 23:53:46 -05:00
Richard Feldman
5a111cb263 Rename drop to deinit, per Zig convention 2020-12-03 23:08:30 -05:00
Richard Feldman
83529079cf allocateStr uses @sizeOf(usize) instead of 8 2020-12-03 23:01:46 -05:00
Richard Feldman
0583cc1a27 Use camelCase in str.zig 2020-12-03 22:58:19 -05:00
Richard Feldman
31fd70d0b1
Merge branch 'trunk' into str-from-int 2020-12-03 22:26:23 -05:00
Richard Feldman
567e0e6a8f
Merge pull request #765 from rtfeldman/list-refcount-issues
Fix some list refcount issues
2020-12-03 22:23:21 -05:00