code: private boolean validUnionTypeExpression(Node expr) {
      // The expression must have at least three children: The union keyword and
      // two type expressions
      if (!checkParameterCount(expr, Keywords.UNION)) {
        return false;
      }
      int paramCount = getCallParamCount(expr);
      // Check if each of the members of the union is a valid type expression
      for (int i = 0; i < paramCount; i++) {
        if (!validTypeTransformationExpression(getCallArgument(expr, i))) {
          warnInvalidInside("union type", expr);
          return false;
        }
      }
      return true;
    }
docs: A Union type expression must be a valid type variable or
  a union(TTLExp, TTLExp, ...)