Details
-
Improvement
-
Resolution: Duplicate
-
Normal
-
2.0.0
-
None
Description
There are places where a format is all text, in a ordinary byte encoding like ascii or utf-8, yet alignmentFillParser is still inserted.
The optimization depends on this logic, which is not correct, as it never actually looks to see if something is of byte length at all.
final override lazy val isKnownToBePrecededByAllByteLengthItems: Boolean = {
|
val es = nearestEnclosingSequence
|
es match {
|
case None => true
|
case Some(s) => {
|
if (s.groupMembers.head eq this) s.isKnownToBePrecededByAllByteLengthItems
|
else {
|
//pass for now
|
val index = s.groupMembers.indexOf(this)
|
s.groupMembers.slice(0, index).forall { _.isKnownToBePrecededByAllByteLengthItems }
|
}
|
}
|
}
|
}
|