-
Notifications
You must be signed in to change notification settings - Fork 35
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
Resolve ambiguities in https://github.com/jonniedie/ComponentArrays.jl/pull/231 #230
Conversation
This reverts commit e71eaae.
Codecov ReportAttention:
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## main #230 +/- ##
==========================================
- Coverage 73.45% 73.32% -0.14%
==========================================
Files 23 23
Lines 746 746
==========================================
- Hits 548 547 -1
- Misses 198 199 +1 ☔ View full report in Codecov by Sentry. |
ok tests are passing on < 1.10 now. Gonna test on 1.10 next |
The MethodError: vcat(::ComponentVector{Float64, Vector{Float64}, Tuple{Axis{(a = 1, b = 2:3, c = ViewAxis(4:10, Axis(a = ViewAxis(1:3, Axis(a = 1, b = 2:3)), b = 4:7)))}}}, ::ComponentVector{Float64, Vector{Float64}, Tuple{Axis{(a = 1, b = 2:3, c = ViewAxis(4:10, Axis(a = ViewAxis(1:3, Axis(a = 1, b = 2:3)), b = 4:7)))}}}, ::ComponentVector{Float64, Vector{Float64}, Tuple{Axis{(a = 1, b = 2:3, c = ViewAxis(4:10, Axis(a = ViewAxis(1:3, Axis(a = 1, b = 2:3)), b = 4:7)))}}}) is ambiguous.
Candidates:
vcat(x::ComponentVector, args...)
@ ComponentArrays ~/work/ComponentArrays.jl/ComponentArrays.jl/src/array_interface.jl:61
vcat(x::ComponentVector, args::Union{Number, UniformScaling, AbstractVecOrMat}...)
@ ComponentArrays ~/work/ComponentArrays.jl/ComponentArrays.jl/src/array_interface.jl:62
vcat(x::ComponentVector, args::Vararg{AbstractVector{T}, N}) where {T, N}
@ ComponentArrays ~/work/ComponentArrays.jl/ComponentArrays.jl/src/array_interface.jl:63
vcat(X::Union{Number, AbstractVecOrMat{<:Number}}...)
@ SparseArrays /opt/hostedtoolcache/julia/1.10.0-beta3/x64/share/julia/stdlib/v1.10/SparseArrays/src/sparsevector.jl:1229
vcat(A::Union{Number, AbstractArray, UniformScaling}...)
@ LinearAlgebra /opt/hostedtoolcache/julia/1.10.0-beta3/x64/share/julia/stdlib/v1.10/LinearAlgebra/src/uniformscaling.jl:428
vcat(A::Union{AbstractArray, UniformScaling}...)
@ LinearAlgebra /opt/hostedtoolcache/julia/1.10.0-beta3/x64/share/julia/stdlib/v1.10/LinearAlgebra/src/uniformscaling.jl:426
vcat(A::Union{Number, AbstractArray}...)
@ Base abstractarray.jl:1992
vcat(A::AbstractArray...)
@ Base abstractarray.jl:1991
vcat(A::AbstractVecOrMat...)
@ Base abstractarray.jl:1682
vcat(V::AbstractVector...)
@ Base abstractarray.jl:1612
vcat(A::AbstractVecOrMat{T}...) where T
@ Base abstractarray.jl:1683
vcat(V::AbstractVector{T}...) where T
@ Base abstractarray.jl:1613
To resolve the ambiguity, try making one of the methods more specific, or adding a new method more specific than any of the existing applicable methods. |
@jonniedie can you help with ^? |
Might not be able to get to this today. But how are other array packages handling it? Seems like everyone should be hitting the same problem. |
which packages are you talking about? |
… with SparseArrays in julia v1.10
I made the methods more specific, and tests are passing locally |
@jonniedie looks like this is good to go. Bumping version. |
Co-authored-by: Jonnie Diegelman <[email protected]>
… as type parameters are already curried
This reverts commit 16506f4.
all comments have been resolved |
@jonniedie can we merge? |
Sorry for the delay, was busy with school work. @jonniedie addressed your latest comment |
1 similar comment
@jonniedie ping |
Thanks for doing this. One last ask, though: would you mind making a test case of the example you gave above so this will have coverage? |
To avoid conflict with
https://github.com/JuliaSparse/SparseArrays.jl/blob/main/src/sparsevector.jl#L1242-L1247
without this PR:
with this PR: