// a pointer computed from a live object is a borrow of it: fine while the owner lives struct node { int v; node* next; }; fn main() { let p = new(4); p[0] = 11; p[1] = 22; let q = p + 1; put_n(q[-1]); put_c(' '); put_n(q[0]); put_c(' '); node* a = new(node), b = new(node); a.v = 3; b.v = 4; a.next = b; node* c = a.next; put_n(c.v); put_c(' '); int** list = new(int*, 2); int* item = new(int); *item = 8; list[1] = item; int* e = list[1]; put_n(*e); put_c(10); free(d*p); free(d*a); free(d*list); return 0; }