You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@SethTisue said:
This is a consequence of filterKeys being lazy, so the lambdas just stack up. I would suggest using filter here since there is no need for the lazy behavior.
If it's surprising that filterKeys is lazy, that's covered by #4776 (and, a while earlier, #751). As for the problem that stacking up lazy operations tends to result in eventual stack overflows, that's a pervasive issue in Scala collections and in Scala generally; ultimately we have the lack of tail calls on the JVM to thank.
I'm not sure if this even a bug, or just a feature. However:
This code will throw StackOverflowError
This would not:
This will throw as well:
The text was updated successfully, but these errors were encountered: