File tree Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -5,13 +5,15 @@ struct VariableInput end
5
5
struct VariableOutput end
6
6
struct VariableIrreducible end
7
7
struct VariableStatePriority end
8
+ struct VariableMisc end
8
9
Symbolics. option_to_metadata_type (:: Val{:unit} ) = VariableUnit
9
10
Symbolics. option_to_metadata_type (:: Val{:connect} ) = VariableConnectType
10
11
Symbolics. option_to_metadata_type (:: Val{:noise} ) = VariableNoiseType
11
12
Symbolics. option_to_metadata_type (:: Val{:input} ) = VariableInput
12
13
Symbolics. option_to_metadata_type (:: Val{:output} ) = VariableOutput
13
14
Symbolics. option_to_metadata_type (:: Val{:irreducible} ) = VariableIrreducible
14
15
Symbolics. option_to_metadata_type (:: Val{:state_priority} ) = VariableStatePriority
16
+ Symbolics. option_to_metadata_type (:: Val{:misc} ) = VariableMisc
15
17
16
18
abstract type AbstractConnectType end
17
19
struct Equality <: AbstractConnectType end # Equality connection
Original file line number Diff line number Diff line change 264
264
@test isequal (x, (i = 12 , name = :x ))
265
265
@test isequal (y, [(i = 13 , name = Symbol (:y_ , i)) for i in 1 : 3 ])
266
266
@test isequal (xys, [x; y])
267
+
268
+ @variables x [misc = " wow" ]
269
+ @test SymbolicUtils. getmetadata (Symbolics. unwrap (x), ModelingToolkit. VariableMisc,
270
+ nothing ) == " wow"
271
+ @parameters x [misc = " wow" ]
272
+ @test SymbolicUtils. getmetadata (Symbolics. unwrap (x), ModelingToolkit. VariableMisc,
273
+ nothing ) == " wow"
You can’t perform that action at this time.
0 commit comments