[Ur] sourcing a record
Gergely Buday
gbuday at gmail.com
Tue Sep 27 09:31:59 EDT 2011
Hi,
I would like to express a function that computes the source of each
member of a record and produces a new record of them.
Upon reading chapter 2 of the tutorial, I arrived to the following,
which, of course, does not work:
fun sourcify [ r ::: {Type} ] (record : r) : ($(map (fn n =>
transaction (source n))) r) =
@fold [ fn t => transaction (source t)) ] (fn [nm ::_] [ v::_]
[r::_] [[nm=m]~r] value => [nm = source m ++ value]) {} record
How could this be written properly?
- Gergely
More information about the Ur
mailing list