Skip to content

Commit

Permalink
🤖 Format .jl files (#261)
Browse files Browse the repository at this point in the history
Co-authored-by: dpo <[email protected]>
  • Loading branch information
github-actions[bot] and dpo authored Mar 16, 2024
1 parent 3ed9f92 commit 8d2e8d2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
7 changes: 5 additions & 2 deletions src/fomo.jl
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,10 @@ end
"""
mutable struct R2Solver{T, V} <: AbstractOptimizationSolver end

Base.@deprecate R2Solver(nlp::AbstractNLPModel; kwargs...) FoSolver(nlp::AbstractNLPModel; kwargs...)
Base.@deprecate R2Solver(nlp::AbstractNLPModel; kwargs...) FoSolver(
nlp::AbstractNLPModel;
kwargs...,
)

@doc (@doc FoSolver) function fo(nlp::AbstractNLPModel{T, V}; kwargs...) where {T, V}
solver = FoSolver(nlp)
Expand Down Expand Up @@ -479,4 +482,4 @@ end

function step_mult::T, norm_∇fk::T, ::tr_step) where {T}
α / norm_∇fk
end
end
3 changes: 2 additions & 1 deletion test/allocs.jl
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ end

if Sys.isunix()
@testset "Allocation tests" begin
@testset "$symsolver" for symsolver in (:LBFGSSolver, :FoSolver, :FomoSolver, :TrunkSolver, :TronSolver)
@testset "$symsolver" for symsolver in
(:LBFGSSolver, :FoSolver, :FomoSolver, :TrunkSolver, :TronSolver)
for model in NLPModelsTest.nlp_problems
nlp = eval(Meta.parse(model))()
if unconstrained(nlp) || (bound_constrained(nlp) && (symsolver == :TronSolver))
Expand Down

0 comments on commit 8d2e8d2

Please sign in to comment.