-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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 example codes (2019-03) #7569
fix example codes (2019-03) #7569
Conversation
- Fix missing end quote on the code example - Fix typo - TODO: hash.cr:162 ``` no overload matches 'Array(Int32)#dig?' with types String, String, String Overloads are: - Indexable(T)#dig?(index : Int) - Indexable(T)#dig?(index : Int, *subindexes) value.dig?(*subkeys) ```
- Fix typo - 1212341515125412412412421 doesn't fit in an UInt64
- Fix typo
- Fix to use comment rather than spec
- Fix undefined constant Params
- Fix expecting token ')', not '127.0'
- Fix humanize_XXX
- Fix to work
- Add missing `each` - Fix typo
- Fix typo
- Fix typo
- Fix Index out of bounds (IndexError)
- Fix for strict typing - Catch up the latest API of JSON
- Fix typo
That overflow behavior seems worrying. |
The error with |
There's a bug with named arguments and autocasting but I can't remember what was it or how to reproduce it. |
You need to compiler the snippet with The flag that you mention is for the compiler to overflow on runtime, but does not mean that the generated program have that. It's an opt-in preview feature. |
revert this because it was a wrong change Co-Authored-By: maiha <[email protected]>
Yep, it helps to reduce the heuristics built in here. 😺 |
- crystal-lang/crystal#7569 (comment) - passed `src/exception.cr`
Yep, it worked! 😺 |
Thank you very much @maiha 👍 |
* upstream/master: fix example codes (2019-03) (crystal-lang#7569) Change bsearch's `/ 2` to `>> 1` for faster performance (crystal-lang#7531) Don't include private constants in the docs (crystal-lang#7575) Add missing `require` statements for the API (A-N) (crystal-lang#7564) Implement Int#{leading,trailing}_zeros_count (crystal-lang#7520)
Hi all, it is time to catch up the examples code once a year.
a17a65617 Implement Int#{leading,trailing}_zeros_count (#7520)
)For convenience, commits are divided file by file, so please apply squash merge.
NOTE
Aside from PR, there are three points that I was worried about.
1. humanize
2.
Hash#dig?
3.
Int32::MAX + 1
doesn't raiseOverflow
Although the compiled compiler was build with default setting
-D preview_overflow -D compiler_rt ...
, I can't find the overflow action.Best regards,