mirror of
https://github.com/sigmasternchen/xtext-core
synced 2025-03-16 16:58:56 +00:00
[serilizer] fixed two bugs spotted by findbugs
- fixed GenericSyntacticSequencer - didn't modify behaviour of GrammarConstraintProvider to avoid regressions; I'd rather deprecate the GrammarConstraintProvider. Signed-off-by: Moritz Eysholdt <moritz.eysholdt@itemis.de>
This commit is contained in:
parent
7cfdafd988
commit
6aa392bf19
2 changed files with 2 additions and 2 deletions
|
@ -1036,7 +1036,7 @@ public class GrammarConstraintProvider implements IGrammarConstraintProvider {
|
|||
else
|
||||
return isOptional ? null : INVALID;
|
||||
} else
|
||||
new ConstraintElement(context, getConstraintElementType(ele), ele);
|
||||
return null; //new ConstraintElement(context, getConstraintElementType(ele), ele);
|
||||
} else if (ele instanceof RuleCall) {
|
||||
RuleCall rc = (RuleCall) ele;
|
||||
if (GrammarUtil.isUnassignedEObjectRuleCall(rc)) {
|
||||
|
|
|
@ -33,7 +33,7 @@ public class GenericSyntacticSequencer extends AbstractSyntacticSequencer {
|
|||
if (rule.getAlternatives() instanceof Alternatives)
|
||||
for (AbstractElement ele : ((Alternatives) rule.getAlternatives()).getElements())
|
||||
if (ele instanceof Keyword)
|
||||
((Keyword) ele).getValue();
|
||||
return ((Keyword) ele).getValue();
|
||||
}
|
||||
return "";
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue