--
You received this message because you are subscribed to the Google Groups "ats-lang-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ats-lang-user...@googlegroups.com.
To post to this group, send email to ats-lan...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ats-lang-users/CAAZxu4zLZDhBG02p%3D4d4hrYAMM1n1-x8CdyO07mGB_%3DLAVYYKg%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ats-lang-users/CAORbNRoRig0dqP%3Ddr%3D6htPnHt4Ba2R7oNNis%3Dm8wHJSKciuPRQ%40mail.gmail.com.
//
extern
fun{
a:t@ype
} some_fun{n:nat}
(!arrayptr (a, n), !arrayptr (a, n)): void
//
(* ****** ****** *)
implement
main0 ((*void*)) =
{
//
val A =
(arrayptr)$arrpsz{int}(0, 1)
//
val (fpf | A2) =
decode ($vcopyenv_vt(A))
val () = some_fun<int> (A, A2)
prval ((*void*)) = fpf (A2)
//
val () = arrayptr_free (A)
//
} (* end of [main0] *)
So in ATS2, I presume this wouldn't be done with specialized views, but rather read/write functions?
To view this discussion on the web visit https://groups.google.com/d/msgid/ats-lang-users/a45c842a-9222-4b91-9d38-1640f5f5f176%40googlegroups.com.