<br><div><span class="gmail_quote">On 6/1/07, <b class="gmail_sendername">Andreas Rossberg</b> <<a href="mailto:AndreasRossberg@web.de">AndreasRossberg@web.de</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
From: "Matthew Fluet" <<a href="mailto:fluet@tti-c.org">fluet@tti-c.org</a>><br>><br>>> What most likely does break defunctorisation, though, is the combination<br>>> of first-class and higher-order modules.
<br>><br>> I think just first-class modules (with or without higher-order modules)<br>> would compromise defunctorisation. At the very least, it wouldn't look<br>> like a 'classic' defunctorisation.
<br><br>First-class modules without higher-order ones would imply (or at least I<br>meant that to imply) that you could not make functors first-class, i.e. you<br>only would have first-class structures. Wouldn't defunctorisation still be
<br>applicable in that case? (Of course, monomorphisation would break.)<br></blockquote><div><br>Agreed, if by "defunctorization" one means just "eliminate functors".
<br>(Which is a more than valid interpretation.)
<br>
<br>I guess what I was getting at is a more general interpretation of
<br>"defunctorization", meaning that one eliminates all module-level
<br>constructs by a (simple) translation into core-level constructs.
<br>
<br>I don't think that you can turn first-class (first-order) structures
<br>into core-level ML. As you note elsewhere in the thread, you
<br>immediately get first-class polymorphism and first-class existentials,
<br>so core-ML isn't expressive enough. I think you could play a
<br>defunctorization like trick to 'tag' each first-class structure to
<br>differentiate the first-class structures that could flow to the same
<br>unpacking. But, this would certainly require more deep thought.
<br><br>
</div></div>