code: @Nullable
    private static Object getInstance(Tree tree, VisitorState state) {
      Object value = ASTHelpers.constValue(tree);
      if (value != null) {
        return value;
      }
      Type type = ASTHelpers.getType(tree);
      return getInstance(type, state);
    }
docs: Return an instance of the given type if it receives special handling by {@code String.format}.
  For example, an intance of {@link Integer} will be returned for an input of type {@code int} or
  {@link Integer}.