@@ -428,7 +428,7 @@ Search for the analysis point with the given `name` in `get_eqs(sys)`.
428428function analysis_point_index (sys:: AbstractSystem , name:: Symbol )
429429 name = namespace_hierarchy (name)[end ]
430430 findfirst (get_eqs (sys)) do eq
431- eq. lhs isa AnalysisPoint && nameof (eq. rhs) == name
431+ value ( eq. lhs) isa AnalysisPoint && nameof (value ( eq. rhs) :: AnalysisPoint ) == name
432432 end
433433end
434434
@@ -540,7 +540,7 @@ function apply_transformation(tf::Break, sys::AbstractSystem)
540540 breaksys_eqs = copy (get_eqs (breaksys))
541541 @set! breaksys. eqs = breaksys_eqs
542542
543- ap = breaksys_eqs[ap_idx]. rhs
543+ ap = value ( breaksys_eqs[ap_idx]. rhs) :: AnalysisPoint
544544 deleteat! (breaksys_eqs, ap_idx)
545545
546546 breaksys = with_analysis_point_ignored (breaksys, ap)
@@ -598,7 +598,7 @@ function apply_transformation(tf::GetInput, sys::AbstractSystem)
598598 error (" Analysis point $(nameof (tf. ap)) not found in system $(nameof (sys)) ." )
599599 # get the analysis point
600600 ap_sys_eqs = get_eqs (ap_sys)
601- ap = ap_sys_eqs[ap_idx]. rhs
601+ ap = value ( ap_sys_eqs[ap_idx]. rhs) :: AnalysisPoint
602602
603603 # input variable
604604 ap_ivar = ap_var (ap. input)
@@ -653,7 +653,7 @@ function apply_transformation(tf::PerturbOutput, sys::AbstractSystem)
653653 # modified equations
654654 ap_sys_eqs = copy (get_eqs (ap_sys))
655655 @set! ap_sys. eqs = ap_sys_eqs
656- ap = ap_sys_eqs[ap_idx]. rhs
656+ ap = value ( ap_sys_eqs[ap_idx]. rhs) :: AnalysisPoint
657657 # remove analysis point
658658 deleteat! (ap_sys_eqs, ap_idx)
659659 ap_sys = with_analysis_point_ignored (ap_sys, ap)
@@ -723,7 +723,7 @@ function apply_transformation(tf::AddVariable, sys::AbstractSystem)
723723 ap_idx === nothing &&
724724 error (" Analysis point $(nameof (tf. ap)) not found in system $(nameof (sys)) ." )
725725 ap_sys_eqs = get_eqs (ap_sys)
726- ap = ap_sys_eqs[ap_idx]. rhs
726+ ap = value ( ap_sys_eqs[ap_idx]. rhs) :: AnalysisPoint
727727
728728 # add equations involving new variable
729729 ap_ivar = ap_var (ap. input)
0 commit comments