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


   ### What changes were proposed in this pull request?
   There are 5 api related to `java.io.Serializable` interface:
   
   - private void writeObject(java.io.ObjectOutputStream out) throws IOException
   - private void readObject(java.io.ObjectInputStream in) throws IOException, 
ClassNotFoundException;
   - private void readObjectNoData() throws ObjectStreamException;
   - ANY-ACCESS-MODIFIER Object writeReplace() throws ObjectStreamException;
   - ANY-ACCESS-MODIFIER Object readResolve() throws ObjectStreamException;
   
   And the implementations of these methods is mistaken for unused in Spark 
code, for example Intellij identify them as `Declaration is never used` and in 
we enabled the compilation options related to `unused`, there will also be 
relevant compilation warning log.
   
   So this pr add `@nowarn` for this method to suppress related warnings, the 
added rules are as follows:
   
   - If it has one instance in a file, it uses it without importing 
(@scala.annotation.nowarn)
   - If it has more than one instances, it imports
   
   
   ### Why are the changes needed?
   Suppress unwanted warnings
   
   
   
   ### Does this PR introduce _any_ user-facing change?
   No
   
   
   ### How was this patch tested?
   Pass GA


-- 
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