You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by bu...@apache.org on 2001/03/19 17:24:09 UTC

[Bug 1023] New - min/max Inclusive/Exclusive out of bound errors not reported by the parser for the datatype long

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=1023

*** shadow/1023	Mon Mar 19 08:24:09 2001
--- shadow/1023.tmp.5375	Mon Mar 19 08:24:09 2001
***************
*** 0 ****
--- 1,48 ----
+ +============================================================================+
+ | min/max Inclusive/Exclusive out of bound errors not reported by the parser |
+ +----------------------------------------------------------------------------+
+ |        Bug #: 1023                        Product: Xerces-J                |
+ |       Status: NEW                         Version: 1.3.0                   |
+ |   Resolution:                            Platform: PC                      |
+ |     Severity: Normal                   OS/Version:                         |
+ |     Priority: Medium                    Component: Schema-Datatypes        |
+ +----------------------------------------------------------------------------+
+ |  Assigned To: xerces-j-dev@xml.apache.org                                  |
+ |  Reported By: nddelima@ca.ibm.com                                          |
+ |      CC list: Cc:                                                          |
+ +----------------------------------------------------------------------------+
+ |          URL:                                                              |
+ +============================================================================+
+ |                              DESCRIPTION                                   |
+ The datatype long is derived from integer by setting the value of maxInclusive 
+ to 9223372036854775807 and minInclusive to -9223372036854775808 and so has its 
+ boundary values as -9223372036854775808 and 9223372036854775807.  However an 
+ error is not raised by the parser when values for the factes min/max 
+ Inclusive/Exclusive specified in a schema are out of bounds.  
+ 
+ A sample schema that does not raise an error is as below:
+ Sample schema:  TestSchema.xsd
+ <?xml version="1.0"?>
+ <schema xmlns="http://www.w3.org/2000/10/XMLSchema"
+ 	targetNamespace="http://www.schemaTest.org/Test"
+ 	xmlns:dv="http://www.schemaTest.org/Test">
+ 
+ <simpleType name="mylong">
+ 	<restriction base="long">
+ 	      <minInclusive value="-9223372036854775809"/>
+ 	      <maxInclusive value="92233720368547758099999"/>
+ 	</restriction>
+ </simpleType>
+ 
+ <element name="root">
+ 	<complexType>
+ 		<sequence>
+ 			<element name="mylong_1" type="dv:mylong" minOccurs="1" 
+ maxOccurs="unbounded"/>
+ 		</sequence>
+ 	</complexType>
+ </element>
+ </schema>
+ 
+ Reference:
+ IBM Schema invalid test ibmd3_3_14si03 fails with min/max Exclusive

---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-dev-help@xml.apache.org