Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/mcs/defmcs.jl
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ macro defsim(expr)
# TBD: need to generalize this to support other methods
return :(Simulation{$simdatatype}(
[$(_rvs...)],
[$(_transforms...)],
TransformSpec[$(_transforms...)],
Tuple{Symbol, Symbol}[$(_saves...)],
$data))
end
Expand Down
9 changes: 9 additions & 0 deletions src/mcs/mcs_types.jl
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,15 @@ mutable struct Simulation{T}
end
end

"""
Simulation{T}() where T <: AbstractSimulationData

Allow creation of an "empty" Simulation instance.
"""
function Simulation{T}() where T <: AbstractSimulationData
Simulation{T}([], TransformSpec[], Tuple{Symbol, Symbol}[], T())
end

"""
set_payload!(sim::Simulation, payload)

Expand Down