src/Generic/PropTree/Predicate.cpp
// Symbols used by Predicate::validPredicate(), which checks against a 
// short list of common, invalid predicates (eg, "'s", etc).
// Pythia version omits "'s". I'm restoring it, but not sure if it should be

Symbols used by Predicate::validPredicate(), which checks against a
short list of common, invalid predicates .
Pythia version omits "'s". I'm restoring it, but not sure if it should be
Symbols used by Predicate :: validPredicate () which checks against a short list of common invalid predicates . Pythia version omits " ' s " . I ' m restoring it but not sure if it should be
bool Predicate::validPredicate( const Symbol & p ){
	static bool init = false;
	static std::set<Symbol> invalidPredicates;
	if (!init) {
		std::string input_file = ParamReader::getParam("invalid_proptree_predicates");
		if (!input_file.empty()) {
			invalidPredicates = InputUtil::readFileIntoSymbolSet(input_file, false, true);
		}
		invalidPredicates.insert(L"");
		invalidPredicates.insert(L"'s");
		invalidPredicates.insert(L"/");
		invalidPredicates.insert(L"\\");
		invalidPredicates.insert(L"-");
		init = true;
	}
	Symbol lower_p = SymbolUtilities::lowercaseSymbol(p);
	return (invalidPredicates.size() == 0 || invalidPredicates.find(lower_p) == invalidPredicates.end());
}
bool Predicate :: validPredicate ( const Symbol & p ) { static bool init = false ; static std :: set < Symbol > invalidPredicates ; if ( ! init ) { std :: string input_file = ParamReader :: getParam ( " " ) ; if ( ! input_file . empty ( ) ) { invalidPredicates = InputUtil :: readFileIntoSymbolSet ( input_file , false , true ) ; } invalidPredicates . insert ( L" " ) ; invalidPredicates . insert ( L" " ) ; invalidPredicates . insert ( L" " ) ; invalidPredicates . insert ( L" \\ " ) ; invalidPredicates . insert ( L" " ) ; init = true ; } Symbol lower_p = SymbolUtilities :: lowercaseSymbol ( p ) ; return ( invalidPredicates . size ( ) == 0 || invalidPredicates . find ( lower_p ) == invalidPredicates . end ( ) ) ; }
Symbols used by Predicate::validPredicate(), which checks against a
short list of common, invalid predicates (eg, "'s", etc).
Symbols used by Predicate :: validPredicate () which checks against a short list of common invalid predicates ( eg " ' s " etc ) .