I stumbled upon this bug when working on DFDL-368. Instead of having:
<tdml:document>
<tdml:documentPart type="byte">00000033</tdml:documentPart>
<tdml:documentPart type="text"><![CDATA[000118Ridgewood Circle Rochester NY123]]></tdml:documentPart>
</tdml:document>
I forgot to include the "byte" line and was getting a java.lang.OutOfMemory Exception. A test case has been added to daffodil-test/src/test/scala-debug/daffodil/section12/lengthKind/TestLengthKindExplicitDebug.scala as part of commit 63ec5eec94a077b32f5d477554f5dcf65d1706c4