-
-
Notifications
You must be signed in to change notification settings - Fork 331
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
fix rescue’s default behavior #687
Conversation
When no type is given, “rescue” should catch StandardError by default, *NOT* all types of Exceptions.
There is some weird bug on my last commit, fails on mri 2.0 and 2.2 (the only two run mspec on travis?) I can confirm this is the only test having trouble.
|
anyway, found another bug related.
nothing printed due to a missing EDIT:
|
one more serious bug on
|
Got caught by the latter a few days ago, anyway I'm (slowly) working to bring in CRuby tests, maybe they cover these cases. |
Previously only the first two rescues were being compiled. ref: #687 (comment)
Previously only the first two rescues were being compiled. ref: #687 (comment)
@elia, the bug on one line rescue is still not resolved. You may want to open another ticket.
To illustrate
Compile result doesn't give variable "a" any val because of missing return in
Extra brackets yield correct result
|
@huochunpeng thanks! |
Previously only the first two rescues were being compiled. ref: #687 (comment)
Previously only the first two rescues were being compiled. ref: #687 (comment)
Previously only the first two rescues were being compiled. ref: #687 (comment)
Previously only the first two rescues were being compiled. ref: #687 (comment)
Previously only the first two rescues were being compiled. ref: opal#687 (comment)
When no type is given, “rescue” should catch StandardError by default,
NOT all types of Exceptions.
I am surprised
rubyspec
'scorelib/language/rescue_spec.rb
did not test this.