jadams-tresys commented on a change in pull request #262: Unordered sequences
URL: https://github.com/apache/incubator-daffodil/pull/262#discussion_r324228868
 
 

 ##########
 File path: 
daffodil-core/src/main/scala/org/apache/daffodil/grammar/AlignedMixin.scala
 ##########
 @@ -170,18 +172,29 @@ trait AlignedMixin extends GrammarMixin { self: Term =>
           Seq()
         }
 
+      val unorderedSequenceSelfAlignment =
+        if (isInUnorderedSequence) {
+          Seq(alignmentApprox + (elementSpecifiedLengthApprox + 
trailingSkipApprox))
+        } else {
+          Seq()
+        }
+
       val priorSibsAlignmentsApprox = priorSibs.map { ps =>
-        val eaa = ps.endingAlignmentApprox
+        val eaa = if (isInUnorderedSequence) {
+          alignmentApprox + (elementSpecifiedLengthApprox + trailingSkipApprox)
 
 Review comment:
   I can't say I fully understand the alignment code, but I think this is OK, I 
just forgot to call **ps**.elementSpecifiedLengthApprox + 
**ps.**trailingSkipApprox, which works as expected.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to