-
-
Notifications
You must be signed in to change notification settings - Fork 133
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
JsObject should return immutable collections (play-json 2.8/ scala 2.13) #388
Comments
After checking out play json, I realized that So my suggestion would be
|
This is a backwards-incompatible change. The way to go here is to add new variants that are immutable and deprecate the mutable ones. So, ok for
|
@14mr0n, forgot to mention. PRs are super welcome! 😉 |
@renatocaval thanks for clarification. I'll happily do this changes and open a PR in the next days. :) |
I might also jump on this when/if my workload permits. |
Any updates on this issue? I'm able to fix it right now if needed. |
@RichardMarto no updates and I don't think anyone is working on it. Feel free to pick. Let me know if you do it so I assign to you just to signal to others that someone is already on it. |
I'm just not sure about which version should be in |
Is there any documentation that needs to be updated? |
I think I misunderstood something. |
This also affects JsError and other in this file due to this import, would be great to have it fixed:
|
I was just migrating to scala 2.13 and realised, that the only collections related migration I had to do, was with JsObject. I was using this two fields
What I found interesting is, that even the second comment says
immutable map
andunderlying.toSeq
is returning animmutable.Seq
the return values arecollection.Map
andcollection.Seq
. This seems odd to me. Especially because immutable collections should be considered the default, since it is what is defined in predef now (2.13).Are there any good reasons to not change this to immutable?
The text was updated successfully, but these errors were encountered: