Skip to content

Commit

Permalink
Add broadcast support
Browse files Browse the repository at this point in the history
  • Loading branch information
YingboMa committed Feb 21, 2024
1 parent 78d4200 commit c0061d4
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Blocks/analysis_points.jl
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
using ModelingToolkit: get_eqs, vars, @set!, get_iv

Base.@kwdef mutable struct AnalysisPoint <: Real
Base.@kwdef mutable struct AnalysisPoint
in = nothing
out = nothing
name::Symbol = :nothing
end
Base.broadcastable(x::AnalysisPoint) = (x,)

Check warning on line 8 in src/Blocks/analysis_points.jl

View check run for this annotation

Codecov / codecov/patch

src/Blocks/analysis_points.jl#L8

Added line #L8 was not covered by tests
if Base.isdefined(ModelingToolkit, :isconnection)

Check warning on line 9 in src/Blocks/analysis_points.jl

View workflow job for this annotation

GitHub Actions / Spell Check with Typos

"isconnection" should be "isconnected".
ModelingToolkit.isconnection(::AnalysisPoint) = true

Check warning on line 10 in src/Blocks/analysis_points.jl

View workflow job for this annotation

GitHub Actions / Spell Check with Typos

"isconnection" should be "isconnected".

Check warning on line 10 in src/Blocks/analysis_points.jl

View check run for this annotation

Codecov / codecov/patch

src/Blocks/analysis_points.jl#L10

Added line #L10 was not covered by tests
end
Expand Down

0 comments on commit c0061d4

Please sign in to comment.