This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
The expected error code for the test d1e76078 in test set app-Walmsley has been modified. The test is: declare variable $array1 := ["abc","def","ghi","jkl"]; array:subarray($array1,6) And now expects FOAY0001, rather than FOAY0002. From a strict reading of the spec, I disagree with the change. The spec currently says "raise [err:FOAY0001] if $start is less than one"; but it does not say raise this error if $start is greater than array:size($array) (perhaps this is a spec bug??). It says "The two-argument version of the function returns the same result (or the same error) as the three-argument version when called with $length equal to the value of array:size($array) - $start + 1." So in this case, $length is calculated to be -1, and then we get "raise [err:FOAY0002] if $length is less than zero."
The WG decided to treat this as a bug against F&O spec
The WG made some disapproving noises about the fact that the test had been changed without consultation. The WG decided to change the specification of array:subarray() so that FOAY0001 is raised in this case, as expected by the revised test. The specification has been changed accordingly, and the test results stand.
Typo in the spec change. In the amended line: A dynamic error is raised [err:FOAY0001] if $start is less than one or greater than array:size($array) + 1. The final "+ 1" is incorrect, it should just be "...or greater than array:size($array)."
Sorry, ignore my last comment; the change is correct. $start is allowed to be array:size($array) + 1 to return an empty array.