Skip to content

Commit f5b45bf

Browse files
committed
params(::SemSpec) support
1 parent 19b16d4 commit f5b45bf

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

src/frontend/specification/ParameterTable.jl

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -142,9 +142,6 @@ Base.iterate(partable::ParameterTable) = iterate(partable, 1)
142142
Base.iterate(partable::ParameterTable, i::Integer) =
143143
i > length(partable) ? nothing : (partable[i], i + 1)
144144

145-
params(partable::ParameterTable) = partable.params
146-
nparams(partable::ParameterTable) = length(params(partable))
147-
148145
# Sorting ----------------------------------------------------------------------------------
149146

150147
struct CyclicModelError <: Exception

src/types.jl

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -275,4 +275,7 @@ Base type for all SEM specifications.
275275
"""
276276
abstract type SemSpecification end
277277

278+
params(spec::SemSpecification) = spec.params
279+
nparams(spec::SemSpecification) = length(params(spec))
280+
278281
abstract type AbstractParameterTable <: SemSpecification end

0 commit comments

Comments
 (0)