This is an automated email from the ASF dual-hosted git repository.
huaxingao pushed a commit to branch branch-3.2
in repository https://gitbox.apache.org/repos/asf/spark.git
The following commit(s) were added to refs/heads/branch-3.2 by this push:
new 4cd3fd3 [SPARK-38100][SQL] Remove unused private method in `Decimal`
4cd3fd3 is described below
commit 4cd3fd3152949a57939a850ec18d9eb4bc31fdf7
Author: yangjie01 <[email protected]>
AuthorDate: Thu Feb 3 13:38:10 2022 -0800
[SPARK-38100][SQL] Remove unused private method in `Decimal`
### What changes were proposed in this pull request?
There is an unused `private` method `overflowException` in
`org.apache.spark.sql.types.Decimal`, this method add by SPARK-28741 and the
relevant invocations are replaced by
`QueryExecutionErrors.castingCauseOverflowError` directly after SPARK-35060. So
this pr remove this unused method.
### Why are the changes needed?
Remove unused method.
### Does this PR introduce _any_ user-facing change?
No
### How was this patch tested?
Pass GA
Closes #35392 from LuciferYang/SPARK-38100.
Authored-by: yangjie01 <[email protected]>
Signed-off-by: huaxingao <[email protected]>
(cherry picked from commit 7a613ecb826d3009f4587cefeb89f31b1cb4bed2)
Signed-off-by: huaxingao <[email protected]>
---
sql/catalyst/src/main/scala/org/apache/spark/sql/types/Decimal.scala | 3 ---
1 file changed, 3 deletions(-)
diff --git
a/sql/catalyst/src/main/scala/org/apache/spark/sql/types/Decimal.scala
b/sql/catalyst/src/main/scala/org/apache/spark/sql/types/Decimal.scala
index cb468c5..4681429 100644
--- a/sql/catalyst/src/main/scala/org/apache/spark/sql/types/Decimal.scala
+++ b/sql/catalyst/src/main/scala/org/apache/spark/sql/types/Decimal.scala
@@ -251,9 +251,6 @@ final class Decimal extends Ordered[Decimal] with
Serializable {
def toByte: Byte = toLong.toByte
- private def overflowException(dataType: String) =
- throw QueryExecutionErrors.castingCauseOverflowError(this, dataType)
-
/**
* @return the Byte value that is equal to the rounded decimal.
* @throws ArithmeticException if the decimal is too big to fit in Byte type.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]