Github user chenghao-intel commented on a diff in the pull request:

    https://github.com/apache/spark/pull/9902#discussion_r45688410
  
    --- Diff: 
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/stringExpressions.scala
 ---
    @@ -343,47 +343,71 @@ case class FindInSet(left: Expression, right: 
Expression) extends BinaryExpressi
     }
     
     /**
    - * A function that trim the spaces from both ends for the specified string.
    + * A function that trims the given character (by default space) from both 
ends for given string.
      */
    -case class StringTrim(child: Expression)
    -  extends UnaryExpression with String2StringExpression {
    +case class StringTrim(left: Expression, right: Expression)
    --- End diff --
    
    Nit: I am wondering if we can use more meaningful name, like `expr` and 
`trimChar` for constructor arguments.
    And also add `def left = expr` and `def right = trimChar`.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to