11function sparse_release_matrix_handle (A:: oneAbstractSparseMatrix )
2- if A. handle != = nothing
2+ return if A. handle != = nothing
33 try
44 queue = global_queue (context (A. nzVal), device (A. nzVal))
55 handle_ptr = Ref {matrix_handle_t} (A. handle)
@@ -8,7 +8,7 @@ function sparse_release_matrix_handle(A::oneAbstractSparseMatrix)
88 synchronize (queue)
99 catch err
1010 # Don't let finalizer errors crash the program
11- @warn " Error releasing sparse matrix handle" exception= err
11+ @warn " Error releasing sparse matrix handle" exception = err
1212 end
1313 end
1414end
@@ -117,10 +117,10 @@ for (fname, elty, intty) in ((:onemklSsparse_set_coo_data , :Float32 , :Int3
117117 queue = global_queue (context (nzVal), device (nzVal))
118118 if m != 0 && n != 0
119119 $ fname (sycl_queue (queue), handle_ptr[], m, n, nnzA, ' O' , rowInd, colInd, nzVal)
120- dA = oneSparseMatrixCOO {$elty, $intty} (handle_ptr[], rowInd, colInd, nzVal, (m,n), nnzA)
120+ dA = oneSparseMatrixCOO {$elty, $intty} (handle_ptr[], rowInd, colInd, nzVal, (m, n), nnzA)
121121 finalizer (sparse_release_matrix_handle, dA)
122122 else
123- dA = oneSparseMatrixCOO {$elty, $intty} (nothing , rowInd, colInd, nzVal, (m,n), nnzA)
123+ dA = oneSparseMatrixCOO {$elty, $intty} (nothing , rowInd, colInd, nzVal, (m, n), nnzA)
124124 end
125125 return dA
126126 end
0 commit comments