Skip to content

Commit

Permalink
Throw specific DimensionMismatch error
Browse files Browse the repository at this point in the history
  • Loading branch information
abhro committed Dec 26, 2024
1 parent f2c4d7f commit 6a8a9a9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/green/transform.jl
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,9 @@ DLR Fourier transform of functions on the first temporal grid (`ImTime`, `ImFreq
function Base.:<<(objL::MeshArray{T,N,MT1}, objR::MeshArray{T,N,MT2}) where {T,N,MT1,MT2}
dimL = _find_mesh(MT1, ImTime, ImFreq, DLRFreq)
dimR = _find_mesh(MT2, ImTime, ImFreq, DLRFreq)
@assert dimL == dimR "The temporal dimensions should be identical for source and target MeshArrays."
if dimL != dimR
throw(DimensionMismatch("The temporal dimensions should be identical for source and target MeshArrays."))
end

typeL = typeof(objL.mesh[dimL])
typeR = typeof(objR.mesh[dimR])
Expand Down

0 comments on commit 6a8a9a9

Please sign in to comment.