On Mon, Dec 04, 2006 at 07:05:19PM +0000, Sam Mason wrote: > The C language is notable in its absence of a general purpose allocator > and I'm wondering if BitC should follow suit; maybe leaving "dup" > like functionality to some clever use of type classes (which can be > automatically generated by the compiler like the Eq and Show classes are > for data types in Haskell) and library code.
Not sure if it's quite as easy as I thought before; the main reason for having a "dup" operator seems, to me, to stop references escaping from locations whose type changes unexpectedly (the stack and unions spring to mind). How you could arrange type classes without exposing locations seems difficult. The semantics of "dup" still seem to require a single heap, so I'm not sure how to reconcile this. Sam _______________________________________________ bitc-dev mailing list [email protected] http://www.coyotos.org/mailman/listinfo/bitc-dev
