Skip to content
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

Remove momenttype and use reduction initialization infrastructure #22937

Merged
merged 1 commit into from
Jul 25, 2017

Conversation

andreasnoack
Copy link
Member

for determining the return type.

Adjust return type determination in _quantile

Fixes #22901

@ararslan ararslan added kind:bugfix This change fixes an existing bug domain:maths Mathematical functions labels Jul 24, 2017
@tkelman
Copy link
Contributor

tkelman commented Jul 24, 2017

This is used in DataArrays and a few other packages and would be safer to deprecate

@@ -1569,6 +1569,10 @@ end

@deprecate String(io::GenericIOBuffer) String(take!(copy(io)))

@eval Base begin
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this file is in Base? can set the extra boolean argument to false so it's not exported

@andreasnoack andreasnoack force-pushed the anj/anyvar branch 2 times, most recently from 80a21b7 to 76bbfc8 Compare July 25, 2017 03:20
@@ -1591,6 +1591,10 @@ end
@deprecate readstring(filename::AbstractString) read(filename, String)
@deprecate readstring(cmd::AbstractCmd) read(cmd, String)

@eval Base begin
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this eval shouldn't be needed

for determining the return type.

Adjust return type determination in _quantile

Fixes #22901
@iamed2
Copy link
Contributor

iamed2 commented Jul 25, 2017

Would this fix #21786 ?

@andreasnoack
Copy link
Member Author

It appears so

julia> A = fill(1KiloGram, 2, 2)
2×2 Array{SIUnits.SIQuantity{Int64,0,1,0,0,0,0,0,0,0},2}:
 1 kg   1 kg
 1 kg   1 kg

julia> mean(A, 1)
1×2 Array{SIUnits.SIQuantity{Float64,0,1,0,0,0,0,0,0,0},2}:
 1.0 kg   1.0 kg

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
domain:maths Mathematical functions kind:bugfix This change fixes an existing bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants