External Publication
Visit Post

Pure Borrow: Linear Haskell Meets Rust-Style Borrowing

Haskell Community [Unofficial] April 24, 2026
Source

This is very cool! I’ll read carefully soon.

konn:

Although the Pure Borrow programs work fine after the compilation , we are observing that some vector programs with Pure Borrow (involving copyAt especially) segfaults when interpreted inside GHCi and HLS Eval Plugin. We are working on this problem, so please be patient and please compile your Pure Borrow program to check the output meanwhile

I think I’ve fixed this bug with linear types in GHCi. It should be fixed in 9.14 and 9.12.3. Here are some references:

  • Launch program via GHCi support and questions on linearity · Issue #5 · alt-romes/ghengin · GitHub
  • Segfault with GHCi 9.12.2 and Linear Types (#26565) · Issues · Glasgow Haskell Compiler / GHC · GitLab

Hope that helps!

Discussion in the ATmosphere

Loading comments...