comp.lang.ada
 help / color / mirror / Atom feed
* Implementing Rust's borrow checked pointers
@ 2019-09-24  9:05 Lucretia
  2019-09-24  9:57 ` Dmitry A. Kazakov
                   ` (3 more replies)
  0 siblings, 4 replies; 19+ messages in thread
From: Lucretia @ 2019-09-24  9:05 UTC (permalink / raw)


Hi,

Been talking to someone on Telegraph and he was saying Ada should implement this, just wondering whether Ada could? I posed a slight change to access type specification to do this, what do people think?

type P is restricted access X;

Restricted in this case would mean that once assigned it cannot be re-assigned into or out of with out some sort of move operation, which could be implemented as an attribute on the access type.

A : P := L'Access;
B : P := A'Move; --  A cannot no longer be used.

begin
   A.all ... ; -- raises exception.


I don't know enough about all this to put a complete proposal together, but I think I've got the basics understood.

Luke.

^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2019-09-25 17:21 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-24  9:05 Implementing Rust's borrow checked pointers Lucretia
2019-09-24  9:57 ` Dmitry A. Kazakov
2019-09-24 11:23 ` Optikos
2019-09-24 12:02   ` Lucretia
2019-09-24 14:08     ` Optikos
2019-09-24 18:56     ` Simon Wright
2019-09-24 19:13     ` Keith Thompson
2019-09-24 20:15       ` Optikos
2019-09-24 20:31         ` Keith Thompson
2019-09-24 20:40           ` Optikos
2019-09-24 20:53             ` Keith Thompson
2019-09-24 22:09       ` Lucretia
2019-09-24 22:24         ` Keith Thompson
2019-09-25  4:36         ` J-P. Rosen
2019-09-25 15:04           ` Simon Wright
2019-09-24 12:23 ` Lucretia
2019-09-25 17:21   ` Stephen Leake
2019-09-24 16:24 ` Jeffrey R. Carter
2019-09-25 16:26   ` Florian Weimer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox