From 0166940e38233960d2f14ba1629a0c484968a39b Mon Sep 17 00:00:00 2001 From: Aayush Sabharwal Date: Mon, 1 Jan 2024 21:57:33 +0530 Subject: [PATCH] refactor: format --- src/SymbolicIndexingInterface.jl | 3 ++- src/symbol_cache.jl | 4 +++- test/parameter_indexing_test.jl | 2 +- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/src/SymbolicIndexingInterface.jl b/src/SymbolicIndexingInterface.jl index 7f79e66..4663bdc 100644 --- a/src/SymbolicIndexingInterface.jl +++ b/src/SymbolicIndexingInterface.jl @@ -5,7 +5,8 @@ include("trait.jl") export is_variable, variable_index, variable_symbols, is_parameter, parameter_index, parameter_symbols, is_independent_variable, independent_variable_symbols, is_observed, - observed, is_time_dependent, constant_structure, symbolic_container, all_variable_symbols, + observed, is_time_dependent, constant_structure, symbolic_container, + all_variable_symbols, all_symbols, solvedvariables, allvariables include("interface.jl") diff --git a/src/symbol_cache.jl b/src/symbol_cache.jl index 2509f96..a1f566e 100644 --- a/src/symbol_cache.jl +++ b/src/symbol_cache.jl @@ -72,7 +72,9 @@ function is_time_dependent(sc::SymbolCache) end constant_structure(::SymbolCache) = true all_variable_symbols(sc::SymbolCache) = variable_symbols(sc) -all_symbols(sc::SymbolCache) = vcat(variable_symbols(sc), parameter_symbols(sc), independent_variable_symbols(sc)) +function all_symbols(sc::SymbolCache) + vcat(variable_symbols(sc), parameter_symbols(sc), independent_variable_symbols(sc)) +end function Base.copy(sc::SymbolCache) return SymbolCache(sc.variables === nothing ? nothing : copy(sc.variables), diff --git a/test/parameter_indexing_test.jl b/test/parameter_indexing_test.jl index 455dba7..b67fb61 100644 --- a/test/parameter_indexing_test.jl +++ b/test/parameter_indexing_test.jl @@ -1,7 +1,7 @@ using SymbolicIndexingInterface using Test -struct FakeIntegrator{S,P} +struct FakeIntegrator{S, P} sys::S p::P end