docs: @Nullable
    public static TargetType targetType(VisitorState state) {
      if (!(state.getPath().getLeaf() instanceof ExpressionTree)) {
        return null;
      }
      TreePath parent = state.getPath();
      ExpressionTree current;
      do {
        current = (ExpressionTree) parent.getLeaf();
        parent = parent.getParentPath();
      } while (parent != null && parent.getLeaf().getKind() == Kind.PARENTHESIZED);
  
      if (parent == null) {
        return null;
      }
  
      Type type = new TargetTypeVisitor(current, state, parent).visit(parent.getLeaf(), null);
      if (type == null) {
        return null;
      }
      return TargetType.create(type, parent);
    }