This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 28050 - map:for-each examples missing parenthesis
Summary: map:for-each examples missing parenthesis
Status: CLOSED FIXED
Alias: None
Product: XPath / XQuery / XSLT
Classification: Unclassified
Component: Functions and Operators 3.1 (show other bugs)
Version: Candidate Recommendation
Hardware: PC Windows NT
: P2 trivial
Target Milestone: ---
Assignee: Michael Kay
QA Contact: Mailing list for public feedback on specs from XSL and XML Query WGs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-02-18 15:52 UTC by Priscilla Walmsley
Modified: 2016-12-16 19:55 UTC (History)
0 users

See Also:


Attachments

Description Priscilla Walmsley 2015-02-18 15:52:01 UTC
The description of map:for-each has the following 2 examples:

distinct-values(map:for-each-entry(map{1:"yes", 2:"no"}, function($k, $v){$v})

and 

map:merge(map:for-each(map{"a":1, "b":2}, function($k, $v){map:entry($k, $v+1)})


Both of these should have an extra closing parenthesis ) on the end. Also, the second one is a link to the map:merge definition, which looks a bit strange.
Comment 1 Michael Kay 2015-02-19 18:17:31 UTC
Thanks, I've fixed these editorial errors in both the F+O 3.1 and the XSLT 3.0 specifications.

Unfortunately there's no easy way of fixing the markup: the stylesheets for the F+O spec insert the links to function definitions moronically.