Prototype of Ownership/Borrowing System for D

Ola Fosheim Grostad ola.fosheim.grostad at
Tue Dec 3 06:35:39 UTC 2019

On Monday, 2 December 2019 at 23:18:55 UTC, rikki cattermole 
> I only just watched the talk a couple of hours ago.

Ah, then you have more info on this than me.

> There is one key feature that both of us share.
> Objects life times get owned by a data structure.
> In both of my examples in the code proposal I linked above were 
> based upon just this. Some sort of object (either a class or 
> the double linked lists nodes) is owned by some sort of data 
> structure (Scoped vs DoubleLinkedList).

Ok, maybe I misread the intent you were conveying. Since I 
haven't watched the talk yet, I don't know how they ensure the 
integrity. I would suspect they use the type system...

> I am not convinced about their memory region scheme, based upon 
> the talk it looks to be prone to data races with locks. Which 
> is worrying.

It is possible that they intend to use a verifier that prove that 
deadlocks or starvation cannot happen since they design a new 
language from scratch? Or put that on the programmer?

( they rule out dataraces as only one thread has access to the 

> But so far I'm getting convinced that my idea isn't completely 
> crazy.

Maybe write up something more detailed? I believe "separation 
logic" has been used for partitioning the heap into groups of 
objects, but I don't know how it works... Probably intricate.

> I'm going to try and reach out and get a confirmation on how 
> their memory region system works.

You could ask if they have pointers to papers, perhaps?

More information about the Digitalmars-d mailing list