LuciferYang opened a new pull request, #44977:
URL: https://github.com/apache/spark/pull/44977

   ### What changes were proposed in this pull request?
   This PR simplifies the `getSerializationProxy` function in the 
`IndylambdaScalaClosures`. The main change is to remove the 
`isClosureCandidate` check when determining if a class is a closure because 
Apache Spark 4.0 no longer support Scala 2.11.
   
   
   ### Why are the changes needed?
   The reason for removing the `isClosureCandidate` check is that in Scala 2.12 
and later versions, closures are implemented as synthetic classes generated by 
the Java LambdaMetafactory. These synthetic classes do not need to implement 
the `scala.Function` interface, which is what the `isClosureCandidate` check 
was originally checking for. Therefore, the `isClosureCandidate` check is not 
necessary for identifying closures in Scala 2.12 and later versions.
   
   
   
   ### Does this PR introduce _any_ user-facing change?
   No
   
   
   ### How was this patch tested?
   Pass GitHub Actions
   
   
   ### Was this patch authored or co-authored using generative AI tooling?
   No
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


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

Reply via email to