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

1.8: hcat does not work with uniform scaling #41912

Closed
PetrKryslUCSD opened this issue Aug 18, 2021 · 2 comments
Closed

1.8: hcat does not work with uniform scaling #41912

PetrKryslUCSD opened this issue Aug 18, 2021 · 2 comments

Comments

@PetrKryslUCSD
Copy link

With 1.8, Windows 10:

                                                                           
julia> versioninfo()                                                                 
Julia Version 1.8.0-DEV.151                                                          
Commit 6240d352f1 (2021-07-07 19:24 UTC)                                             
Platform Info:                                                                       
  OS: Windows (x86_64-w64-mingw32)                                                   
  CPU: Intel(R) Core(TM) i7-8705G CPU @ 3.10GHz                                      
  WORD_SIZE: 64                                                                      
  LIBM: libopenlibm                                                                  
  LLVM: libLLVM-12.0.0 (ORCJIT, skylake)                                             
Environment:                                                                         
  JULIA_SSL_CA_ROOTS_PATH =       

julia> Hi = rand(3, 3) + 1im*rand(3, 3)                                              
3×3 Matrix{ComplexF64}:                                                              
 0.747577+0.909602im   0.860573+0.995995im   0.323974+0.304666im                     
 0.454257+0.971077im   0.204695+0.0673943im  0.116131+0.517748im                     
 0.231052+0.0728148im  0.277886+0.244845im   0.738274+0.185219im                     
                                                                                     
julia> hcat(Hi, I)                                                                   
ERROR: MethodError: hcat(::Matrix{ComplexF64}, ::UniformScaling{Bool}) is ambiguous. 
Candidates:                                                                          
  hcat(A::Union{Number, UniformScaling, AbstractVecOrMat}...) in LinearAlgebra at C:\Users\PetrKrysl\julia-1.8-dev\share\julia\stdlib\v1.8\LinearAlgebra\src\uniformscaling.jl:409                                                                             
  hcat(As::Union{UniformScaling, LinearMaps.LinearMap, AbstractVecOrMat{T} where T}...) in LinearMaps at C:\Users\PetrKrysl\.julia\packages\LinearMaps\r6i00\src\blockmap.jl:81                                                                                
Possible fix, define                                                                 
  hcat(::Vararg{Union{UniformScaling, AbstractVecOrMat{T} where T}})                 
Stacktrace:                                                                          
 [1] top-level scope                                                                 
   @ REPL[20]:1                                                                      
@PetrKryslUCSD PetrKryslUCSD changed the title hcat does not work with uniform scaling 1.8: hcat does not work with uniform scaling Aug 18, 2021
@PetrKryslUCSD
Copy link
Author

Works fine with 1.7.3

@sostock
Copy link
Contributor

sostock commented Aug 18, 2021

This is fixed by #41511.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants