public virtual bool IsValidSet(TreeToNFAConverter nfabuilder, GrammarAST t)
{
bool valid = true;
try
{
//[email protected]("parse BLOCK as set tree: "+t.toStringTree());
int alts = nfabuilder.TestBlockAsSet( t );
valid = ( alts > 1 );
}
catch ( RecognitionException /*re*/ )
{
// The rule did not parse as a set, return false; ignore exception
valid = false;
}
//[email protected]("valid? "+valid);
return valid;
}