Announcing #junelang, an experimental safe systems language with a focus on being readable, learnable, and teach-able.
https://www.sophiajt.com/search-for-easier-safe-systems-programming/
Announcing #junelang, an experimental safe systems language with a focus on being readable, learnable, and teach-able.
https://www.sophiajt.com/search-for-easier-safe-systems-programming/
@sophiajt looks awesome! 😄 Looking forward to following the developments.
Quick question, how will `recycle` work on cyclic linked lists? Panic, keep the memory bloat (every pointer is still technically in use once), or somehow detect that the entire cycle can be recycled at once?
it does a trace and then matches the trace count to the copy count. That works for structures with cycles, at least in theory.
perhaps, but I see this is a tooling challenge. We teach the developer about iterative improvement, we enable tracing in debug builds, and we light it up in CI. That way you can still get something to work quickly, and then iterate towards something that's good.
hence the need for tooling
some of the folks I showed do believe that there's a lot of space for static analysis we could explore. Definitely something to look into
@sophiajt @basilehenry Then again, feels like if you do static analysis, you can insert the recycles automatically and you end up with something very similar to Swift’s refcounting.
Sorry to be so critical. I really liked everything in the post except for the manual recycle calls. But if the automatic grouping is good enough that e.g. everything in a web server request gets auto-collected and you never really need the recycles, that would be awesome.
We wouldn't insert them automatically unless the user asks us to update the code. They need to be visible because they're a linear time operation, so the maintainers/reviewers need to see when the recycle happens.