[ 
https://issues.apache.org/jira/browse/DAFFODIL-3095?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Steve Lawrence updated DAFFODIL-3095:
-------------------------------------
    Description: 
This schema snippet uses an xs:integer to represent a field and uses 
min/maxInsclusive to restrict it to the range of int64:

{code:xml}
  <element name="foo" ... >
    <simpleType>
      <restriction base="xs:integer">
        <minInclusive value="-9223372036854775807" />
        <maxInclusive value="9223372036854775807" />
      </restriction>
    </simpleType>
  </element>
{code}

This fails to compile with the error:

{code}
[error] Schema Definition Error: minInclusive facet value 
(-9223372036854775807) was found to be outside of Integer range.
{code}

Additional testing found that minInclusive values less than -2147483648 (int32 
min value) also give a similar error. Daffodil should be using BigInteger for 
xs:integer so we should not have any range restrictiosn for minIncsluve.

The same also occurs for maxInclusive, so it seems this is specific to range 
checking for Integer, and not necessaril specific to a certain facet 
restriction.

  was:
This schema snippet uses an xs:integer to represent a field and uses 
min/maxInsclusive to restrict it to the range of int64:

{code:xml}
  <element name="foo" ... >
    <simpleType>
      <restriction base="xs:integer">
        <minInclusive value="-9223372036854775807" />
        <maxInclusive value="9223372036854775807" />
      </restriction>
    </simpleType>
  </element>
{code}

This fails to compile with the error:

{code}
[error] Schema Definition Error: minInclusive facet value 
(-9223372036854775807) was found to be outside of Integer range.
{code}

Additional testing found that minInclusive values less than-2147483648 (m 


> xs:integer minInclusive facet value found to be outside Integer range 
> ----------------------------------------------------------------------
>
>                 Key: DAFFODIL-3095
>                 URL: https://issues.apache.org/jira/browse/DAFFODIL-3095
>             Project: Daffodil
>          Issue Type: Task
>          Components: Front End
>            Reporter: Steve Lawrence
>            Priority: Major
>             Fix For: 4.3.0
>
>
> This schema snippet uses an xs:integer to represent a field and uses 
> min/maxInsclusive to restrict it to the range of int64:
> {code:xml}
>   <element name="foo" ... >
>     <simpleType>
>       <restriction base="xs:integer">
>         <minInclusive value="-9223372036854775807" />
>         <maxInclusive value="9223372036854775807" />
>       </restriction>
>     </simpleType>
>   </element>
> {code}
> This fails to compile with the error:
> {code}
> [error] Schema Definition Error: minInclusive facet value 
> (-9223372036854775807) was found to be outside of Integer range.
> {code}
> Additional testing found that minInclusive values less than -2147483648 
> (int32 min value) also give a similar error. Daffodil should be using 
> BigInteger for xs:integer so we should not have any range restrictiosn for 
> minIncsluve.
> The same also occurs for maxInclusive, so it seems this is specific to range 
> checking for Integer, and not necessaril specific to a certain facet 
> restriction.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to