Post Adg3nCC8WmnB5794D2 by crc@mastodon.bsd.cafe
 (DIR) More posts by crc@mastodon.bsd.cafe
 (DIR) Post #Adg3nCC8WmnB5794D2 by crc@mastodon.bsd.cafe
       2024-01-09T16:45:31Z
       
       0 likes, 1 repeats
       
       Since Hare now has #OpenBSD support, I'm spending a little time with it. I think I've learned what I need to implement an ilo vm in it, so I'll attempt this tonight.
       
 (DIR) Post #AdhF5vXhxPdJalKUEK by crc@mastodon.bsd.cafe
       2024-01-10T03:02:18Z
       
       0 likes, 1 repeats
       
       I've spend a couple of hours on the ilo in #harelang and it's mostly working. All that's left is the block saving functionality, which I'll try to start on tomorrow. I really need to get a better grasp on the file i/o mechanics, as I failed to get `io::seek` working thus far, and have resorted to doing a very slow read of the block set when seeking a block.Some initial thoughts on Hare as I work on this:I have no issues with the overall syntax. It reminds me a bit of Rust, though it feels a little closer to C. The `=>` form used in `switch` and `match` feels a bit odd to me, but I've used similar things in other languages and it's not a problem.I'm comfortable with the standard library at this point. Some of this is just the sparse documentation, and it's partly due to only having spent a couple of hours reading before starting to use it. I can work out enough to get my little project working, but I'd need to spend more time with it to be productive and write efficient code.I'm not following the style guide, particularly around indenting.I dislike the size of the binaries. The ilo binary is 513k as built, and 320k when stripped. I'm hoping future versions of Hare will improve this.Given that the language and its library are still evolving, I'm not going to sink much time into it once I finish the ilo implementation, but I'll keep an eye on it as it progresses.