I'm sorry. This deserved a better answer than I gave it.

The answer to your question is that the conversion is introduced at static
compile time and performed at run time, so yes, you can expect a naive
runtime to exhaust the heap running the loop (simplified here) that you
proposed:


mutable struct Foo<'a, 'b, 'c> {
 native :: fn 'a 'b -> 'c
 currying :: fn 'a -> 'b -> 'c
}

lambda () {
 while (false) {
    foo.currying = foo.native
    foo.native = foo.currying
  }
}

Wonderful example, by the way. And a great example of why runtime-introduced
hidden allocations are not such a terrific idea.
_______________________________________________
bitc-dev mailing list
[email protected]
http://www.coyotos.org/mailman/listinfo/bitc-dev

Reply via email to