-
Notifications
You must be signed in to change notification settings - Fork 210
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
Add test and update types for Kernel #77
Conversation
def to_s: () -> String | ||
|
||
def trust: () -> self | ||
|
||
def `undef`: (*untyped arg) -> void |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ruby does not have undef
method.
def Array: (NilClass x) -> untyped | ||
| (untyped x) -> ::Array[untyped] | ||
|
||
def BigDecimal: (Integer | Float | Rational | BigDecimal | String initial, ?Integer digits, ?exception: bool exception) -> BigDecimal |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
BigDecimal is a standard library. So it should be defined as an extension.
| (?Class arg0, ?::Array[String] arg1) -> bot | ||
| (?Class arg0, ?String arg1, ?::Array[String] arg2) -> bot | ||
| (String arg0) -> bot | ||
| (?Exception arg0, ?String arg1, ?::Array[String] arg2) -> bot |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the type of fail
should be updated later, but not clear enough how it can be now.
This pull request adds tests for all methods for
Kernel
module. And it updates some types because they are wrong.I gave up writing tests for some methods, because they are difficult.
But
test_*
methods are available for all methods. I put "TODO" comment to the methods I gave up.