Spurious matches
It seems that the matcher is producing spurious matches. When looking at syntax highlighted code, I see things highlighted that are not present in the pattern.
For example, taking the patterns file from #25 (closed), looking at pattern number 2 (see also below) I would expect the matches to contain as ?_visited
leaf nodes only those that have the leaves of the pattern. But looking at the match for IC101A
, I also see, e.g., the leaf CCVS-E-4-1
matched (ID 416776), ANSI-REFERENCE
(ID 416615), and so on.
<subtree id="2" support="24" wsupport="24" size="30">
<DataDivision>
<__directives><match-sequence/></__directives>
<TheWorkingStorageSection>
<WorkingStorageSection>
<TheData>
<DataDecl>
<TheFields>
<__directives><match-set/></__directives>
<DataField>
<__directives><match-sequence/></__directives>
<TheId>
<DataIdent>
FEATURE
</DataIdent>
</TheId>
<ThePicClause>
<PicClause>
X(20)
</PicClause>
</ThePicClause>
<TheValueClause>
<ValueClause>
<TheValue>
<PredefinedLiteral>
<TheCode>
SpaceKeyword
</TheCode>
</PredefinedLiteral>
</TheValue>
</ValueClause>
</TheValueClause>
</DataField>
<DataField>
<__directives><match-sequence/></__directives>
<TheId>
<DataIdent>
CCVS-PGM-ID
</DataIdent>
</TheId>
<ThePicClause>
<PicClause>
X(9)
</PicClause>
</ThePicClause>
</DataField>
</TheFields>
</DataDecl>
</TheData>
</WorkingStorageSection>
</TheWorkingStorageSection>
</DataDivision>
</subtree>