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
Tail recursion behaviour is unspecified #1219
Comments
Imported From: https://issues.scala-lang.org/browse/SI-1219?orig=1 |
Does this still hold true for the current versions? |
@nogurenn if you have a look yourself and find out one way or the other, let us know |
The word "tail" appears 7 times, one of which as "tail recursive", and |
The weird example is tweaked in https://github.com/scala/scala/pull/10162/files (Tweaked not for weirdness but correctness: rename on import is higher precedence than wildcard, undermining the point of the example.) I will supply doc in the annotations section for tailrec and switch. (I also went looking for it.) |
The word "tail" appears only twice in the SLS, both as method names in example 5.3.3. So it appears that the current (rather delicate!) behaviour of tail recursion is in fact a completely unspecified feature. It would be nice if this could be fixed. :-)
The text was updated successfully, but these errors were encountered: