diff --git a/lib/NonlinearSolveFirstOrder/src/solve.jl b/lib/NonlinearSolveFirstOrder/src/solve.jl index e9fc30e2e..51ed5af0a 100644 --- a/lib/NonlinearSolveFirstOrder/src/solve.jl +++ b/lib/NonlinearSolveFirstOrder/src/solve.jl @@ -93,7 +93,9 @@ end function InternalAPI.reinit_self!( cache::GeneralizedFirstOrderAlgorithmCache, args...; p = cache.p, u0 = cache.u, - alias_u0::Bool = false, maxiters = 1000, maxtime = nothing, kwargs... + alias_u0::Bool = hasproperty(cache, :alias_u0) ? cache.alias_u0 : false, + maxiters = hasproperty(cache, :maxiters) ? cache.maxiters : 1000, + maxtime = hasproperty(cache, :maxtime) ? cache.maxtime : nothing, kwargs... ) Utils.reinit_common!(cache, u0, p, alias_u0) diff --git a/lib/NonlinearSolveQuasiNewton/src/solve.jl b/lib/NonlinearSolveQuasiNewton/src/solve.jl index 24e740d3f..1cd8ddd48 100644 --- a/lib/NonlinearSolveQuasiNewton/src/solve.jl +++ b/lib/NonlinearSolveQuasiNewton/src/solve.jl @@ -107,7 +107,9 @@ end function InternalAPI.reinit_self!( cache::QuasiNewtonCache, args...; p = cache.p, u0 = cache.u, - alias_u0::Bool = false, maxiters = 1000, maxtime = nothing, kwargs... + alias_u0::Bool = hasproperty(cache, :alias_u0) ? cache.alias_u0 : false, + maxiters = hasproperty(cache, :maxiters) ? cache.maxiters : 1000, + maxtime = hasproperty(cache, :maxtime) ? cache.maxtime : nothing, kwargs... ) Utils.reinit_common!(cache, u0, p, alias_u0) diff --git a/lib/NonlinearSolveSpectralMethods/src/solve.jl b/lib/NonlinearSolveSpectralMethods/src/solve.jl index ebb8d13a9..1a33e6b7f 100644 --- a/lib/NonlinearSolveSpectralMethods/src/solve.jl +++ b/lib/NonlinearSolveSpectralMethods/src/solve.jl @@ -74,7 +74,9 @@ end function InternalAPI.reinit_self!( cache::GeneralizedDFSaneCache, args...; p = cache.p, u0 = cache.u, - alias_u0::Bool = false, maxiters = 1000, maxtime = nothing, kwargs... + alias_u0::Bool = hasproperty(cache, :alias_u0) ? cache.alias_u0 : false, + maxiters = hasproperty(cache, :maxiters) ? cache.maxiters : 1000, + maxtime = hasproperty(cache, :maxtime) ? cache.maxtime : nothing, kwargs... ) Utils.reinit_common!(cache, u0, p, alias_u0) T = eltype(u0)