Mercurial > repos > public > sbplib_julia
changeset 1475:76b190ca9a27 feature/grids/componentview
Generalize component_type
author | Jonatan Werpers <jonatan@werpers.com> |
---|---|
date | Fri, 01 Dec 2023 13:36:47 +0100 |
parents | 276c38a48aac |
children | 62f9d0387a2a |
files | src/Grids/grid.jl |
diffstat | 1 files changed, 2 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/src/Grids/grid.jl Fri Dec 01 13:34:03 2023 +0100 +++ b/src/Grids/grid.jl Fri Dec 01 13:36:47 2023 +0100 @@ -33,12 +33,10 @@ coordinate_size(g::Grid) = coordinate_size(typeof(g)) # TBD: Name of this function?! """ - component_type(g) + component_type(gf) -The type of the components of the coordinate vector of `Grid` `g`. +The type of the components of `gf`. """ -component_type(::Type{<:Grid{T}}) where T = eltype(T) #TBD: removable? -component_type(g::Grid) = component_type(typeof(g)) component_type(T::Type) = eltype(eltype(T)) component_type(t) = component_type(typeof(t))