titzer / virgil

A fast and lightweight native programming language
1.24k stars 51 forks source link

[libs] Replacing immutable `string` with `Range<byte>` #291

Open linxuanm opened 3 weeks ago

linxuanm commented 3 weeks ago

In Strings.v3, should functions such as equal (here) be replaced with equal(arr1: Range<byte>, arr2: Range<byte>)? I believe this can also be done in other places where the string isn't mutated.