public virtual HashSet<SemanticContext> GetGatedSyntacticPredicatesInNFAConfigurations()
{
int numConfigs = _nfaConfigurations.Count;
HashSet<SemanticContext> synpreds = new HashSet<SemanticContext>();
for ( int i = 0; i < numConfigs; i++ )
{
NFAConfiguration configuration = (NFAConfiguration)_nfaConfigurations[i];
SemanticContext gatedPredExpr =
configuration.SemanticContext.GatedPredicateContext;
// if this is a manual syn pred (gated and syn pred), add
if ( gatedPredExpr != null &&
configuration.SemanticContext.IsSyntacticPredicate )
{
synpreds.Add( configuration.SemanticContext );
}
}
if ( synpreds.Count == 0 )
{
return null;
}
return synpreds;
}