Skip to content

Serializable objects should have a "readResolve" method synthesized #4440

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
smarter opened this issue May 2, 2018 · 1 comment
Closed

Comments

@ingarabr
Copy link
Contributor

ingarabr commented May 2, 2018

I have started working on this one.

ingarabr added a commit to ingarabr/dotty that referenced this issue May 3, 2018
If the object implements the serializable interface and not includes the
readResolve method then we add it. Since it's an object we reference it
to the objects singleton instance.

Resolves issue scala#4440
ingarabr added a commit to ingarabr/dotty that referenced this issue May 7, 2018
If the object implements the serializable interface and not includes the
readResolve method then we add it. Since it's an object we reference it
to the objects singleton instance.

Resolves issue scala#4440
ingarabr added a commit to ingarabr/dotty that referenced this issue May 7, 2018
If the object implements the serializable interface and not includes the
readResolve method then we add it. Since it's an object we reference it
to the objects singleton instance.

Resolves issue scala#4440
ingarabr added a commit to ingarabr/dotty that referenced this issue May 7, 2018
If the object implements the serializable interface and not includes the
readResolve method then we add it. Since it's an object we reference it
to the objects singleton instance.

Resolves issue scala#4440
ingarabr added a commit to ingarabr/dotty that referenced this issue May 7, 2018
If the object implements the serializable interface and not includes the
readResolve method then we add it. Since it's an object we reference it
to the objects singleton instance.

Resolves issue scala#4440
smarter pushed a commit to smarter/dotty that referenced this issue Jan 21, 2019
If the object implements the serializable interface and not includes the
readResolve method then we add it. Since it's an object we reference it
to the objects singleton instance.

Resolves issue scala#4440
smarter pushed a commit to dotty-staging/dotty that referenced this issue Jan 22, 2019
In scala#4450 and Scala 2.12, readResolve is used to make sure deserializing
object returns the singleton instance of the object, but this doesn't
prevent the fields of the objects from being serializable in the first
place even though they're not used. Scala 2.13 switched to using
writeReplace to completely bypass serialization of the object in
scala/scala#7297. This commit adapts this to
Dotty.

Co-Authored-By: Ingar Abrahamsen <[email protected]>
Co-Authored-By: Jason Zaugg <[email protected]>
smarter pushed a commit to dotty-staging/dotty that referenced this issue Jan 22, 2019
In scala#4450 and Scala 2.12, readResolve is used to make sure deserializing
an object returns the singleton instance of the object, but this doesn't
prevent the fields of the objects from being serialized in the first
place even though they're not used. Scala 2.13 switched to using
writeReplace to completely bypass serialization of the object in
scala/scala#7297. This commit adapts this to
Dotty.

Co-Authored-By: Ingar Abrahamsen <[email protected]>
Co-Authored-By: Jason Zaugg <[email protected]>
smarter pushed a commit to dotty-staging/dotty that referenced this issue Jan 22, 2019
In scala#4450 and Scala 2.12, readResolve is used to make sure deserializing
an object returns the singleton instance of the object, but this doesn't
prevent the fields of the objects from being serialized in the first
place even though they're not used. Scala 2.13 switched to using
writeReplace to completely bypass serialization of the object in
scala/scala#7297. This commit adapts this to
Dotty.

Co-Authored-By: Ingar Abrahamsen <[email protected]>
Co-Authored-By: Jason Zaugg <[email protected]>
smarter pushed a commit to dotty-staging/dotty that referenced this issue Jan 22, 2019
In scala#4450 and Scala 2.12, readResolve is used to make sure deserializing
an object returns the singleton instance of the object, but this doesn't
prevent the fields of the objects from being serialized in the first
place even though they're not used. Scala 2.13 switched to using
writeReplace to completely bypass serialization of the object in
scala/scala#7297. This commit adapts this to
Dotty.

Co-Authored-By: Ingar Abrahamsen <[email protected]>
Co-Authored-By: Jason Zaugg <[email protected]>
smarter pushed a commit to smarter/dotty that referenced this issue Jan 25, 2019
In scala#4450 and Scala 2.12, readResolve is used to make sure deserializing
an object returns the singleton instance of the object, but this doesn't
prevent the fields of the objects from being serialized in the first
place even though they're not used. Scala 2.13 switched to using
writeReplace to completely bypass serialization of the object in
scala/scala#7297. This commit adapts this to
Dotty.

Co-Authored-By: Ingar Abrahamsen <[email protected]>
Co-Authored-By: Jason Zaugg <[email protected]>
smarter pushed a commit to dotty-staging/dotty that referenced this issue Jan 25, 2019
In scala#4450 and Scala 2.12, readResolve is used to make sure deserializing
an object returns the singleton instance of the object, but this doesn't
prevent the fields of the objects from being serialized in the first
place even though they're not used. Scala 2.13 switched to using
writeReplace to completely bypass serialization of the object in
scala/scala#7297. This commit adapts this to
Dotty.

Co-Authored-By: Ingar Abrahamsen <[email protected]>
Co-Authored-By: Jason Zaugg <[email protected]>
smarter pushed a commit to dotty-staging/dotty that referenced this issue Jan 25, 2019
In scala#4450 and Scala 2.12, readResolve is used to make sure deserializing
an object returns the singleton instance of the object, but this doesn't
prevent the fields of the objects from being serialized in the first
place even though they're not used. Scala 2.13 switched to using
writeReplace to completely bypass serialization of the object in
scala/scala#7297. This commit adapts this to
Dotty.

Co-Authored-By: Ingar Abrahamsen <[email protected]>
Co-Authored-By: Jason Zaugg <[email protected]>
smarter pushed a commit to dotty-staging/dotty that referenced this issue Jan 25, 2019
In scala#4450 and Scala 2.12, readResolve is used to make sure deserializing
an object returns the singleton instance of the object, but this doesn't
prevent the fields of the objects from being serialized in the first
place even though they're not used. Scala 2.13 switched to using
writeReplace to completely bypass serialization of the object in
scala/scala#7297. This commit adapts this to
Dotty.

Co-Authored-By: Ingar Abrahamsen <[email protected]>
Co-Authored-By: Jason Zaugg <[email protected]>
smarter added a commit to dotty-staging/dotty that referenced this issue Jan 25, 2019
In scala#4450 and Scala 2.12, readResolve is used to make sure deserializing
an object returns the singleton instance of the object, but this doesn't
prevent the fields of the objects from being serialized in the first
place even though they're not used. Scala 2.13 switched to using
writeReplace to completely bypass serialization of the object in
scala/scala#7297. This commit adapts this to
Dotty.

Co-Authored-By: Ingar Abrahamsen <[email protected]>
Co-Authored-By: Jason Zaugg <[email protected]>
smarter added a commit to dotty-staging/dotty that referenced this issue Jan 26, 2019
In scala#4450 and Scala 2.12, readResolve is used to make sure deserializing
an object returns the singleton instance of the object, but this doesn't
prevent the fields of the objects from being serialized in the first
place even though they're not used. Scala 2.13 switched to using
writeReplace to completely bypass serialization of the object in
scala/scala#7297. This commit adapts this to
Dotty.

Co-Authored-By: Ingar Abrahamsen <[email protected]>
Co-Authored-By: Jason Zaugg <[email protected]>
smarter added a commit to dotty-staging/dotty that referenced this issue Feb 2, 2019
In scala#4450 and Scala 2.12, readResolve is used to make sure deserializing
an object returns the singleton instance of the object, but this doesn't
prevent the fields of the objects from being serialized in the first
place even though they're not used. Scala 2.13 switched to using
writeReplace to completely bypass serialization of the object in
scala/scala#7297. This commit adapts this to
Dotty.

Co-Authored-By: Ingar Abrahamsen <[email protected]>
Co-Authored-By: Jason Zaugg <[email protected]>
@smarter smarter closed this as completed in d89e6be Feb 2, 2019
smarter added a commit that referenced this issue Feb 2, 2019
Fix #4440: Do not serialize the content of static objects
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants