eejbyfeldt commented on pull request #33205:
URL: https://github.com/apache/spark/pull/33205#issuecomment-891558552


   > Is there any behavior change you can think of that might affect users?
   
   Hi Sean, thanks for having a look!
   
   This only changes is for case class containing value class. e.g
   ```
   case class IntWrapper(value: Int) extends AnyVal
   case class DatasetModel(wrappedInt: IntWrapper)
   ```
   Before this patch trying to create a `Dataset` using the `DatasetModel` 
would result in rumtime error like:
   ```
   21/08/03 07:50:01 ERROR CodeGenerator: failed to compile: 
org.codehaus.commons.compiler.CompileException: File 'generated.java', Line 85, 
Column 1: Assignment conversion not possible from type "int" to type 
"example.IntWrapper"
   org.codehaus.commons.compiler.CompileException: File 'generated.java', Line 
85, Column 1: Assignment conversion not possible from type "int" to type 
"example.IntWrapper"
        at 
org.codehaus.janino.UnitCompiler.compileError(UnitCompiler.java:12021)
        at 
org.codehaus.janino.UnitCompiler.assignmentConversion(UnitCompiler.java:10851)
        ...
   ```
   
   But with this patch it will work like expected. Unless someone explicitly 
depend on having this failure I don't think there should be any behavior change 
that is noticeable for users.


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