titzer / virgil

A fast and lightweight native programming language

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Change system and pointer APIs to pervasively use the `Range` type

k-sareen opened this issue · comments

Currently APIs such as Ptr.atContents and System.file{Read,Write}K assume the input will be an Array<byte>. Changing to a Range<byte> would make it more general.

I have done some work on this recently, e.g. Pointer.atContents can work with ranges now.

For the built-in System component, I was thinking of adding new methods that take a Range<byte> and then deprecating the old ones. This requires a stable rev, as they must first be introduced into v3i and then (with the Pointer.atContents change above integrated into stable) added the native implementations after the rev.

Yes that makes sense. Sorry for being AWOL again -- just have too many deadlines. Will be more free after mid-April. Might try my hand at making an LSP server again.