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

Josh Adams reassigned DAFFODIL-1989:
------------------------------------

    Assignee: Josh Adams

> lengthKind 'explicit' with expression should not use minLength nor 
> textOutputMinLength
> --------------------------------------------------------------------------------------
>
>                 Key: DAFFODIL-1989
>                 URL: https://issues.apache.org/jira/browse/DAFFODIL-1989
>             Project: Daffodil
>          Issue Type: Bug
>          Components: Back End, Middle "End"
>    Affects Versions: 2.1.0
>            Reporter: Michael Beckerle
>            Assignee: Josh Adams
>            Priority: Major
>             Fix For: 2.3.0
>
>
> Per DFDL Erratum 5.18, if the dfdl:lengthKind is explicit, the facet 
> minLength is NOT used to determine the target length. The target length is 
> the value of the length expression (or constant) directly. The minLength 
> facet is only used for validation (if enabled).
> Code in Daffodil e.g., UnparseTargetLengthInCharactersEv, MinLengthInBitsEv, 
> and UnparseTargetLengthInBitsEv, all take minLength into account even for 
> lengthKind explicit, and do not consider whether the expression is a constant 
> or not. (That check occurs elsewhere, so need not be taken into account, but 
> minLength needs to be disregarded as far as the target length is concerned, 
> but still kept around for validation purposes.)
> Similarly, for types other than string/hexBinary that are text, 
> textOutputMinLength should be ignored if dfdl:lengthKind is explicit, though 
> it is an error if the length is a constant and is out of range for 
> textOutputMinLength.  (Similarly for minLength/maxLength, except that is an 
> SDW)



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to