Skip to content
Merged
Changes from 1 commit
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
4 changes: 2 additions & 2 deletions src/systems/parameter_buffer.jl
Original file line number Diff line number Diff line change
Expand Up @@ -319,8 +319,8 @@ function Base.copy(p::MTKParameters)
initials = copy(p.initials)
discrete = Tuple(eltype(buf) <: Real ? copy(buf) : copy.(buf) for buf in p.discrete)
constant = Tuple(eltype(buf) <: Real ? copy(buf) : copy.(buf) for buf in p.constant)
nonnumeric = copy.(p.nonnumeric)
caches = copy.(p.caches)
nonnumeric = isempty(p.nonnumeric) ? p.nonnumeric : copy.(p.nonnumeric)
caches = isempty(p.caches) ? p.caches : copy.(p.caches)
return MTKParameters(
tunable,
initials,
Expand Down
Loading