private static <T> Supplier<T> lazy(Supplier<? extends T> calculation) {
    return new Supplier<>() {
      Ref<T> calculated;
      @Override
      public T get() {
        return (calculated != null? calculated : (calculated = new Ref<>(calculation.get()))).get();
      }
    };
  }
private static <T> Supplier<T> lazy(Supplier<? extends T> calculation)