Gergely Buday wrote:
Thinking a bit about the original problem, I came to a change of aspect.I need not and must not export the underlying record. Better I should define the following: functor Render(sig con mRecord :: {Type} end) : sig renderToXml : data -> transaction xbody end Upon first call the renderToXml function should compute the underlying record, store it in a source cell and render normally. Upon later calls it should compute the record, compare to the previous one in the source cell, render so that differences are highlighted and store the record in the source cell.
Functor application can't have [transaction] side effects on its own, so you'll probably want to introduce an abstract type in the functor output signature, to stand for the source and any other persistent information. Further, you'll probably want to add a "method" to initialize such a value.
_______________________________________________ Ur mailing list [email protected] http://www.impredicative.com/cgi-bin/mailman/listinfo/ur
