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

deprecate ipermute! in favor of invpermute! #25168

Merged
merged 1 commit into from
Dec 22, 2017
Merged

deprecate ipermute! in favor of invpermute! #25168

merged 1 commit into from
Dec 22, 2017

Conversation

rfourquet
Copy link
Member

This is to be consistent with invperm. And it's more explicit.

@rfourquet rfourquet added the deprecation This change introduces or involves a deprecation label Dec 18, 2017
NEWS.md Outdated
@@ -816,6 +816,8 @@ Deprecated or removed
and `unsafe_get`/`get` can be dropped or replaced with `coalesce`.
`NullException` has been removed.

* `ipermute!` has been deprecated in favor of `invpermute` ([#25168]).
Copy link
Member

Choose a reason for hiding this comment

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

invpermute -> invpermute!?

@@ -363,6 +363,9 @@ end

@deprecate ipermutedims(A::AbstractArray,p) permutedims(A, invperm(p))

# PR #25168
@deprecate ipermute!(a, p::AbstractVector) invpermute!(a, p::AbstractVector)
Copy link
Member

Choose a reason for hiding this comment

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

I don't think the deprecation target should have the type annotation, since @deprecate turns it into function definition which means that on the RHS it's a type assertion.

Copy link
Member Author

Choose a reason for hiding this comment

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

Right, thanks!

@rfourquet
Copy link
Member Author

rfourquet commented Dec 22, 2017

The CI errors are unrelated (libgit2 and ProcessExitedException). As it received support, I will just merge this. Thanks!

@rfourquet rfourquet merged commit 5f14f11 into master Dec 22, 2017
@rfourquet rfourquet deleted the rf/ipermute branch December 22, 2017 20:58
@swt30
Copy link
Contributor

swt30 commented Jun 5, 2018

I can't see this deprecation—i.e. typing Base.ipermute! gives ERROR: UndefVarError: ipermute! not defined, whereas other deprecations like Base.sqrtm give a warning. What's going on there?

@fredrikekre
Copy link
Member

Looks like the deprecations where added to the wrong section and got removed in e858f55

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
deprecation This change introduces or involves a deprecation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants