| BooleanFactor <AND> BooleanTerm
555715
final public Selector BooleanTerm() throws ParseException {
                           Selector left, right=null;
    left = BooleanFactor();
    switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
    case AND:
      jj_consume_token(AND);
      right = BooleanTerm();
      break;
    default:
      jj_la1[1] = jj_gen;
      ;
    }
    if (right == null) {if (true) return left;}
    else {if (true) return new OperatorImpl(Operator.AND, left, right);}
    throw new Error("Missing return statement in function");
  }
670538
private void toBoolean(boolean box) {
        Label nonZero = createLabel();
        Label done = createLabel();
        ifZeroComparisonBranch(nonZero, "!=");
        if (box) {
            TypeDesc newType = TypeDesc.forClass(Boolean.class);
            loadStaticField(newType.getRootName(), "FALSE", newType);
            branch(done);
            nonZero.setLocation();
            loadStaticField(newType.getRootName(), "TRUE", newType);
        }
        else {
            loadConstant(false);
            branch(done);
            nonZero.setLocation();
            loadConstant(true);
        }
        done.setLocation();
    }
949484
public BooleanFormula andWith(BooleanFormula other) {
		if (other.isTrue()) {
			return this;
		}
		if (other.isFalse() || isFalse()) {
			if (booleanTerms == null) {
				booleanTerms = new HashSet<BooleanTerm>();
			} else {
				booleanTerms.clear();
			}
			isSimplified = true;
			return this;
		}
		if (isTrue()) {
			booleanTerms = new HashSet<BooleanTerm>(other.booleanTerms);
			return this;
		}
		BooleanFormula newTerms = new BooleanFormula();
		for (BooleanTerm otherTerm : other) {
			for (BooleanTerm term : booleanTerms) {
				BooleanTerm newTerm = term.andWith(otherTerm);
				if (newTerm != null) {
					newTerms.add(newTerm);
				}
			}
		}
		booleanTerms = newTerms.booleanTerms;
		isSimplified = newTerms.isSimplified;
		return this;
	}
1374769
public static DecomposableMatchBuilder0<Boolean> caseBoolean(boolean b) {
    List<Matcher<Object>> matchers = new ArrayList<>();
    matchers.add(eq(b));

    return new DecomposableMatchBuilder0<>(
        matchers, new PrimitiveFieldExtractor<>(Boolean.class));
  }
1327979
def boolean(value):
    
    if isinstance(value, bool):
        return value

    if value == "":
        return False

    return strtobool(value)
817539
def _cast_boolean(self, value):
        
        if value.lower() not in self._BOOLEANS:
            raise ValueError('Not a boolean: %s' % value)

        return self._BOOLEANS[value.lower()]
416232
def _type_bool(label,default=False):
    """"""
    return label, abstractSearch.nothing, abstractRender.boolen, default
388088
public final boolean_factor_return boolean_factor() throws RecognitionException {
        boolean_factor_return retval = new boolean_factor_return();
        retval.start = input.LT(1);


        CommonTree root_0 = null;

        Token NOT5=null;
        predicate_return predicate4 =null;

        predicate_return predicate6 =null;


        CommonTree NOT5_tree=null;
        RewriteRuleTokenStream stream_NOT=new RewriteRuleTokenStream(adaptor,"token NOT");
        RewriteRuleSubtreeStream stream_predicate=new RewriteRuleSubtreeStream(adaptor,"rule predicate");
        try {
            // MessageFilter.g:112:2: ( predicate | NOT predicate -> ^( NOT predicate ) )
            int alt4=2;
            int LA4_0 = input.LA(1);

            if ( (LA4_0==EXISTS||LA4_0==FALSE||LA4_0==TRUE||(LA4_0 >= XPATH_FUN_NAME && LA4_0 <= 33)) ) {
                alt4=1;
            }
            else if ( (LA4_0==NOT) ) {
                alt4=2;
            }
            else {
                NoViableAltException nvae =
                    new NoViableAltException("", 4, 0, input);

                throw nvae;

            }
            switch (alt4) {
                case 1 :
                    // MessageFilter.g:112:4: predicate
                    {
                    root_0 = (CommonTree)adaptor.nil();


                    pushFollow(FOLLOW_predicate_in_boolean_factor414);
                    predicate4=predicate();

                    state._fsp--;

                    adaptor.addChild(root_0, predicate4.getTree());

                    }
                    break;
                case 2 :
                    // MessageFilter.g:113:6: NOT predicate
                    {
                    NOT5=(Token)match(input,NOT,FOLLOW_NOT_in_boolean_factor423);
                    stream_NOT.add(NOT5);


                    pushFollow(FOLLOW_predicate_in_boolean_factor425);
                    predicate6=predicate();

                    state._fsp--;

                    stream_predicate.add(predicate6.getTree());

                    // AST REWRITE
                    // elements: NOT, predicate
                    // token labels:
                    // rule labels: retval
                    // token list labels:
                    // rule list labels:
                    // wildcard labels:
                    retval.tree = root_0;
                    RewriteRuleSubtreeStream stream_retval=new RewriteRuleSubtreeStream(adaptor,"rule retval",retval!=null?retval.tree:null);

                    root_0 = (CommonTree)adaptor.nil();
                    // 113:20: -> ^( NOT predicate )
                    {
                        // MessageFilter.g:113:23: ^( NOT predicate )
                        {
                        CommonTree root_1 = (CommonTree)adaptor.nil();
                        root_1 = (CommonTree)adaptor.becomeRoot(
                        new NotTreeNode(stream_NOT.nextToken())
                        , root_1);

                        adaptor.addChild(root_1, stream_predicate.nextTree());

                        adaptor.addChild(root_0, root_1);
                        }

                    }


                    retval.tree = root_0;

                    }
                    break;

            }
            retval.stop = input.LT(-1);


            retval.tree = (CommonTree)adaptor.rulePostProcessing(root_0);
            adaptor.setTokenBoundaries(retval.tree, retval.start, retval.stop);

        }
        catch (RecognitionException re) {
            reportError(re);
            recover(input,re);
    	retval.tree = (CommonTree)adaptor.errorNode(input, retval.start, input.LT(-1), re);

        }

        finally {
        	// do for sure before leaving
        }
        return retval;
    }
1030099
def _check_for_boolean_pair_reduction(self, kwargs):
        """"""

        if 'reduction_forcing_pairs' in self._meta_data:
            for key1, key2 in self._meta_data['reduction_forcing_pairs']:
                kwargs = self._reduce_boolean_pair(kwargs, key1, key2)
        return kwargs
996279
def BooleanSlice(input_vertex: vertex_constructor_param_types, dimension: int, index: int, label: Optional[str]=None) -> Vertex:
    
    return Boolean(context.jvm_view().BooleanSliceVertex, label, cast_to_vertex(input_vertex), cast_to_integer(dimension), cast_to_integer(index))
1231032
def boolean_input(self, question, default=None):
        '''
        
        '''
        result = input("%s: " % question)
        if not result and default is not None:
            return default
        while len(result) < 1 or result[0].lower() not in "yn":
            result = input("Please answer yes or no: ")
        return result[0].lower() == "y"
1075049
function parseBoolean(value, context) {
    if (value === true || value === 'true') return true;
    if (value === false || value === 'false') return false;
    throw new ImplementationError(`Invalid boolean value "${value}"${context.errorContext}`);
}
896087
protected boolean isPrimitiveBoolean(JvmTypeReference typeRef) {
		if (InferredTypeIndicator.isInferred(typeRef)) {
			return false;
		}
		
		return typeRef != null && typeRef.getType() != null &&
				!typeRef.getType().eIsProxy() &&
				"boolean".equals(typeRef.getType().getIdentifier());
	}
486927
function isBooleanBinaryExpression(node) {
    return node.kind === ts.SyntaxKind.BinaryExpression && binaryBooleanExpressionKind(node) !== undefined;
}
1242658
function parse_BoolErr(blob, length, opts) {
	var cell = parse_XLSCell(blob, 6);
	if(opts.biff == 2) ++blob.l;
	var val = parse_Bes(blob, 2);
	cell.val = val;
	cell.t = (val === true || val === false) ? 'b' : 'e';
	return cell;
}
968472
private static int isAlwaysDefinedBoolean(Node node) {
        switch (node.getType()) {
          case Token.FALSE:
          case Token.NULL:
            return ALWAYS_FALSE_BOOLEAN;
          case Token.TRUE:
            return ALWAYS_TRUE_BOOLEAN;
          case Token.NUMBER: {
            double num = node.getDouble();
            if (num == num && num != 0.0) {
                return ALWAYS_TRUE_BOOLEAN;
            }
            return ALWAYS_FALSE_BOOLEAN;
          }
        }
        return 0;
    }
1139089
def BinaryBool(pred):
    
    class Predicate(Bool):
        def __init__(self, value, ignore_case=False):
            self.value = caseless(value) if ignore_case else value
            self.ignore_case = ignore_case

        def __call__(self, data):
            if not isinstance(data, list):
                data = [data]
            for d in data:
                try:
                    if pred(caseless(d) if self.ignore_case else d, self.value):
                        return True
                except:
                    pass
            return False
    return Predicate