Skip to content

Commit 9dd6d2f

Browse files
committed
generalize MultiFace getindex to Integer
1 parent 2547025 commit 9dd6d2f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/basic_types.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ MultiFace{Names}(args...) where {Names} = MultiFace(NamedTuple{Names}(args))
6767
MultiFace{Names}(args::Tuple{Vararg{<: AbstractFace}}) where {Names} = MultiFace(NamedTuple{Names}(args))
6868
MultiFace{Names, FT}(args) where {Names, FT <: AbstractFace} = MultiFace(NamedTuple{Names}(FT.(args)))
6969

70-
Base.getindex(f::MultiFace, i::Int64) = Base.getindex(getfield(f, :faces), i) # TODO: StaticVector should index with Integer
70+
Base.getindex(f::MultiFace, i::Integer) = Base.getindex(getfield(f, :faces), i)
7171
@inline Base.hasproperty(f::MultiFace, field::Symbol) = hasproperty(getfield(f, :faces), field)
7272
@inline Base.getproperty(f::MultiFace, field::Symbol) = getproperty(getfield(f, :faces), field)
7373
@inline Base.propertynames(f::MultiFace) = propertynames(getfield(f, :faces))

0 commit comments

Comments
 (0)