diff --git a/src/problems/bvp_problems.jl b/src/problems/bvp_problems.jl index 9e8638ef5..de206460e 100644 --- a/src/problems/bvp_problems.jl +++ b/src/problems/bvp_problems.jl @@ -95,8 +95,8 @@ struct BVProblem{uType, tType, isinplace, P, F, BF, PT, K} <: _tspan = promote_tspan(tspan) warn_paramtype(p) new{typeof(u0), typeof(_tspan), iip, typeof(p), - typeof(f), typeof(bc), - typeof(problem_type), typeof(kwargs)}(f, f.bc, u0, _tspan, p, + typeof(f.f), typeof(bc), + typeof(problem_type), typeof(kwargs)}(f.f, bc, u0, _tspan, p, problem_type, kwargs) end @@ -107,16 +107,12 @@ end TruncatedStacktraces.@truncate_stacktrace BVProblem 3 1 2 -function BVProblem(f::AbstractBVPFunction, bc, u0, tspan, args...; kwargs...) - BVProblem{isinplace(f, 4)}(f, bc, u0, tspan, args...; kwargs...) -end - function BVProblem(f, bc, u0, tspan, p = NullParameters(); kwargs...) - BVProblem(BVPFunction(f, bc), bc, u0, tspan, p; kwargs...) + BVProblem(BVPFunction(f, bc), u0, tspan, p; kwargs...) end function BVProblem(f::AbstractBVPFunction, u0, tspan, p = NullParameters(); kwargs...) - BVProblem(f, f.bc, u0, tspan, p; kwargs...) + BVProblem{isinplace(f)}(f.f, f.bc, u0, tspan, p; kwargs...) end # convenience interfaces: diff --git a/src/problems/sde_problems.jl b/src/problems/sde_problems.jl index b7ab7ca71..79d06f732 100644 --- a/src/problems/sde_problems.jl +++ b/src/problems/sde_problems.jl @@ -103,9 +103,9 @@ struct SDEProblem{uType, tType, isinplace, P, NP, F, G, K, ND} <: warn_paramtype(p) new{typeof(u0), typeof(_tspan), isinplace(f), typeof(p), - typeof(noise), typeof(f), typeof(f.g), + typeof(noise), typeof(f.f), typeof(g), typeof(kwargs), - typeof(noise_rate_prototype)}(f, f.g, u0, _tspan, p, + typeof(noise_rate_prototype)}(f.f, g, u0, _tspan, p, noise, kwargs, noise_rate_prototype, seed) end @@ -123,16 +123,12 @@ function SDEProblem(f::AbstractSDEFunction,u0,tspan,p=NullParameters();kwargs... end =# -function SDEProblem(f::AbstractSDEFunction, g, u0, tspan, p = NullParameters(); kwargs...) - SDEProblem{isinplace(f, 4)}(f, g, u0, tspan, p; kwargs...) -end - function SDEProblem(f, g, u0, tspan, p = NullParameters(); kwargs...) - SDEProblem(SDEFunction(f, g), g, u0, tspan, p; kwargs...) + SDEProblem(SDEFunction(f, g), u0, tspan, p; kwargs...) end function SDEProblem(f::AbstractSDEFunction, u0, tspan, p = NullParameters(); kwargs...) - SDEProblem(f, f.g, u0, tspan, p; kwargs...) + SDEProblem{isinplace(f)}(f.f, f.g, u0, tspan, p; kwargs...) end """