- From: <bugzilla@jessica.w3.org>
- Date: Fri, 10 Jun 2016 20:16:15 +0000
- To: public-qt-comments@w3.org
https://www.w3.org/Bugs/Public/show_bug.cgi?id=29080
--- Comment #6 from Christian Gruen <christian.gruen@gmail.com> ---
I see that the implicit conversion of array members to new arrays is probably
not as obvious as I thought it would possibly be. And indeed it may be
necessary to flatten/atomize the looped entries.
To continue with John’s example (thanks for your helpful remarks), my notion
was that people would automatically use array:join to rebuild arrays:
let $arr := [1, 2, (), 4]
return array:join(
for $i in array:members($arr)
where exists($i?*)
return $i
)
Or, shorter:
array:join(array:members($arr)[exists(?*)])
As the example shows, the following check would always yield true:
fn:deep-equal($array, array:join(array:members($array))
Originally, I expected array:for-each to be the best candidate to process all
array entries, but it has been decided that the function will always return a
new array.
--
You are receiving this mail because:
You are the QA Contact for the bug.
Received on Friday, 10 June 2016 20:16:18 UTC