- From: Ashok Malhotra <ashokma@microsoft.com>
- Date: Fri, 18 Apr 2003 11:32:14 -0700
- To: <public-qt-comments@w3.org>
- Message-ID: <E5B814702B65CB4DA51644580E4853FB07A7B116@red-msg-12.redmond.corp.microsoft.com>
The definition of op:numeric-divide is not specific enough in how integer and decimal operands should be handled. Should they be converted to double and a zero divisor be handled by the double division returning + or -INF, or should the divisor be checked for zero before converting to double. I suggest we change the details to one of the paragraphs below. My, not very strong, preference is the first paragraph. For xs:decimal and xs:integer operands, the operands are first converted to xs:double. For xs:float and xs:double operands, floating point division is preformed as specified in [IEEE 754-1985] <http://lists.w3.org/Archives/Member/w3c-archive/2003Feb/att-0150/xquery -operators.html> . For xs:decimal and xs:integer operands, the divisor is checked first. If it is 0, then an error is raised ("Division by zero"). The operands are then converted to xs:double. For xs:float and xs:double operands, floating point division is preformed as specified in [IEEE 754-1985] <http://lists.w3.org/Archives/Member/w3c-archive/2003Feb/att-0150/xquery -operators.html> . All the best, Ashok
Received on Friday, 18 April 2003 14:32:11 UTC