File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change 164164
165165using  LinearAlgebra:  Diagonal
166166@interface  :: AbstractArrayInterface  storedvalues (D:: Diagonal ) =  LinearAlgebra. diag (D)
167+ 
168+ #  compat with LTS:
169+ @static  if  VERSION  ≥  v "" 
170+   _diagind =  LinearAlgebra. diagind
171+ else 
172+   function  _diagind (x:: Diagonal , :: IndexCartesian )
173+     return  view (CartesianIndices (x), LinearAlgebra. diagind (x))
174+   end 
175+ end 
167176@interface  :: AbstractArrayInterface  eachstoredindex (D:: Diagonal ) = 
168-   LinearAlgebra. diagind (D, IndexCartesian ())
177+   _diagind (D, IndexCartesian ())
178+ 
169179@interface  :: AbstractArrayInterface  isstored (D:: Diagonal , i:: Int , j:: Int ) = 
170180  i ==  j &&  Base. checkbounds (Bool, D, i, j)
171181@interface  :: AbstractArrayInterface  function  getstoredindex (D:: Diagonal , i:: Int , j:: Int )
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments