[
https://issues.apache.org/jira/browse/DAFFODIL-2596?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Dave Thompson reopened DAFFODIL-2596:
-------------------------------------
Assignee: Josh Adams
In trying to reproduce the original issue I rolled back to a pre-fix commit and
copied the .tdml and associated scala files (inputTypeCalc.tdml and
TestInputValueCalc.scala) from the fix commit .
Did “git clean -xdf” and “sbt clean” command and deleted the content of .ivy2.
Entered sbt environment and ran “testOnly
org.apache.daffodil.extensions.TestInputTypeValueCalc”.
Both of the new tests, “test_RepType_lengthKind_inherited_01” and
“test_InputTypeCalc_unparse_keysetValue_03” passed when they should have
failed.
> lengthKind property is not inherited for types with dfdlx:repType
> -----------------------------------------------------------------
>
> Key: DAFFODIL-2596
> URL: https://issues.apache.org/jira/browse/DAFFODIL-2596
> Project: Daffodil
> Issue Type: Bug
> Components: Front End
> Affects Versions: 3.2.0
> Reporter: Josh Adams
> Assignee: Josh Adams
> Priority: Major
> Fix For: 3.3.0
>
>
> Ran into this while working on a customer schema
> Essentially if the default dfdl:lengthKind="implicit" and you attempt to use
> a dfdl:repType that involves uses string values for its enumeration, you will
> either get an error complaining that you cannot have an xs:string with
> lengthKind="implicit" without specifying a maxLength, OR for some unknown
> reason you can get a completely different usage error:
> org.apache.daffodil.exceptions.Abort: Usage error: v.>=(0)
> org.apache.daffodil.exceptions.Assert$.abort(Assert.scala:137)
> org.apache.daffodil.util.MaybeULong$.apply(MaybeULong.scala:54)
> org.apache.daffodil.util.MaybeJULong$.apply(MaybeULong.scala:84)
> org.apache.daffodil.processors.LengthInBitsEvBase.compute(EvElement.scala:144)
> at org.apache.daffodil.exceptions.Assert$.abort(Assert.scala:137)
> at org.apache.daffodil.util.MaybeULong$.apply(MaybeULong.scala:54)
> at org.apache.daffodil.util.MaybeJULong$.apply(MaybeULong.scala:84)
> at
> org.apache.daffodil.processors.LengthInBitsEvBase.compute(EvElement.scala:144)
> at
> org.apache.daffodil.processors.LengthInBitsEvBase.compute(EvElement.scala:118)
> at
> org.apache.daffodil.processors.Evaluatable.evaluate(Evaluatable.scala:281)
> at
> org.apache.daffodil.processors.Evaluatable.compileTimeEvaluate(Evaluatable.scala:212)
> at
> org.apache.daffodil.processors.Evaluatable.compile(Evaluatable.scala:317)
> at
> org.apache.daffodil.processors.Evaluatable.compile(Evaluatable.scala:326)
--
This message was sent by Atlassian Jira
(v8.20.1#820001)