I think (if I understand your and my argument correctly) that I only
want a unification of the two ideas into a single syntax sine I think we
are agreeing.
For example(using the foobar external definition example):
Using locations to reference a single variable:
(let-location ((i integer 42))
(foobar (location i))
(print "i is now 43: " i))
Using s32vector to reference a single variable:
(let ((i (s32vector 42)))
(foobar i)
(print "i is now 43: " (s32vector-ref i 0)))
To me, those should be the same since they represent the same thing from the
point of view of the C interface, whose prototype is void foobar(int*) no
matter which method you use above.
I very much like your (location ...) abstraction however. Maybe it can be
made more general.
(location 's32vector var)
(location 'integer var)
(location 'unsigned-int var)
Now, let-location doesn't even exist(if I understand it correctly),
and the compiler possibly at compile time can check to see if this is
true with the binding passed to it.