[Bug 29353] Lossless map:merge

https://www.w3.org/Bugs/Public/show_bug.cgi?id=29353

Michael Kay <mike@saxonica.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |mike@saxonica.com

--- Comment #1 from Michael Kay <mike@saxonica.com> ---
Your desired function can be written

function f:merge-entries($m1, $m2) {
  map:merge(
    for $k in distinct-values((map:keys($m1), map:keys($m2))
    return map{$k : ($m1($k), $m2($k))}
  )
}

which doesn't feel inelegant to me, and if it's inefficient, that's an
implementation problem.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.

Received on Thursday, 31 December 2015 08:22:52 UTC