-
-
Notifications
You must be signed in to change notification settings - Fork 116
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
A few fixes for 0.6 #290
A few fixes for 0.6 #290
Conversation
# julia#19088 | ||
let io = IOBuffer() | ||
write(io, "aaa") | ||
@test take!(io) == UInt8['a', 'a', 'a'] |
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.
Why not test String(take!(io))
too? Otherwise, +1.
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.
Sure. It's actually tested twice above already.
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.
Yes, but it doesn't hurt to do that explicitly here too.
* `num` and `den` rename * `takebuf_array` rename * Fix `$` in the test
46f1a81
to
c3e42bc
Compare
@@ -126,6 +126,10 @@ Currently, the `@compat` macro supports the following syntaxes: | |||
|
|||
* `$` is now `xor` or `⊻` [#18977](https://github.com/JuliaLang/julia/pull/18977). | |||
|
|||
* `num` and `den` are now `numerator` and `denominator` [#19246](https://github.com/JuliaLang/julia/pull/19246). | |||
|
|||
* `takebuf_array` is now a method of `take!`. `takebuf_string(io)` becomes `String(take!(io))` [#19088](https://github.com/JuliaLang/julia/pull/19088). |
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.
Shouldn't this be Compat.UTF8String(take!(io))
thanks to the Compat.String
mess?
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.
No, I believe takebuf_string
on 0.4 is actually type unstable. It can return either ASCIIString
or UTF8String
.
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.
Then we need to define a ByteString(::Array{UInt8}) method
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.
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.
Is there anything that's broken? This won't work before the specific 0.4 commit but Compat.jl already require 0.4.0 now. Travis tests also seems to be passing on 0.4?
Right, sorry, we already have it |
* `num` and `den` rename * `takebuf_array` rename * Fix `$` in the test
* Remove `take!(::Task)` definition for Julia versions prior to 0.6 Was added in #307. * Remove `redirect_std*(f, stream)` definitions for Julia prior to v0.6 Were added in #275. * Remove at-__DIR__ macro definition for Julia versions prior to 0.6 Was added in #281. * Remove `broadcast` definition for equal-length tuples Was added in #324 and #328 * Remove definitions of `unsafe_get` and `isnull` fallsback Were added in #287. * Remove defintions of `xor` and `⊻` Were added in #289. * Definitions of `numerator` and `denominator` Were added in #290. * Remove defintion of `iszero` Was added in #305. * Remove definition of `>:` Was added in #336 * Remove definition of `take!(::Base.AbstractIOBuffer)` Was added in #290. * Remove definiton of `.&` and `.|` Were added in #306. * Remove definition of `Compat.isapprox` Was added in #309.
num
andden
renametakebuf_array
rename$
in the test