fn-format-number third parameter breaks when empty sequence

Bug #1090163 reported by Juan Zacarias
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Zorba
New
Critical
Paul J. Lucas

Bug Description

Failing test: numberformat86

The W3C signature for this functions specifies the third parameter to be able to use an empty sequence
fn:format-number($value as numeric?,
  $picture as xs:string,
  $decimal-format-name as xs:string?) as xs:string

Query
format-number(0.4857,'###.###%', ())

Error
Expected result: 48.57%. Found error XPTY0004 - The query (ed24a61a-2606-4691-bce8-f85d00b53605) evaluated using xqxq:evaluate raised an error at line 8 column 1: The query (7863f2ae-3b45-49fb-98ca-57f6411cbe4b) evaluated using xqxq:evaluate raised an error at line 6 column 34: empty-sequence() can not be promoted to parameter type xs:string of function format-number()

Tags: fots
Changed in zorba:
importance: Undecided → Critical
assignee: nobody → Paul J. Lucas (paul-lucas)
milestone: none → 2.9
summary: - FOTS: fn-format-number third parameter breaks when empty sequence
+ fn-format-number third parameter breaks when empty sequence
tags: added: fots
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.