Skip to content

Commit 0454f1c

Browse files
committed
add use of alias_f, alias_p kwargs for ODiffEq
1 parent 75449c2 commit 0454f1c

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

lib/OrdinaryDiffEqCore/src/solve.jl

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -157,8 +157,18 @@ function DiffEqBase.__init(
157157
else
158158
_alg = alg
159159
end
160-
f = prob.f
161-
p = prob.p
160+
161+
if aliases.alias_f
162+
f = prob.f
163+
else
164+
f = deepcopy(prob.f)
165+
end
166+
167+
if aliases.alias_p
168+
p = prob.p
169+
else
170+
p = recursivecopy(prob.p)
171+
end
162172

163173
use_old_kwargs = haskey(kwargs,:alias_u0) || haskey(kwargs,:alias_du0)
164174

0 commit comments

Comments
 (0)