public static boolean evaluate(IncrementallyUpdatedFilterPredicate pred) {
    return Objects.requireNonNull(pred, "pred cannot be null").accept(INSTANCE);
  }
@Test
  public void testShortCircuit() {
    ValueInspector neverCalled = new ValueInspector() {
      @Override
      public boolean accept(Visitor visitor) {
        throw new ShortCircuitException();
      }
    };

    try {
      evaluate(neverCalled);
      fail("this should throw");
    } catch (ShortCircuitException e) {
      //
    }

    // T || X should evaluate to true without inspecting X
    ValueInspector v = intIsEven();
    v.update(10);
    IncrementallyUpdatedFilterPredicate or = new Or(v, neverCalled);
    assertTrue(evaluate(or));
    v.reset();

    // F && X should evaluate to false without inspecting X
    v.update(11);
    IncrementallyUpdatedFilterPredicate and = new And(v, neverCalled);
    assertFalse(evaluate(and));
    v.reset();
  }