Skip to content

Commit dc9017d

Browse files
committed
formatting
1 parent de07c5a commit dc9017d

File tree

1 file changed

+6
-8
lines changed

1 file changed

+6
-8
lines changed

src/MOI_wrapper.jl

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ function MOI.copy_to(dest::Optimizer, src::MOI.ModelLike)
152152

153153
#check all model/variable/constraint attributes to
154154
#ensure that everything passed is handled by the solver
155-
copy_to_check_attributes(dest,src)
155+
copy_to_check_attributes(dest, src)
156156

157157
MOI.empty!(dest)
158158
idxmap = MOIU.IndexMap(dest, src)
@@ -176,7 +176,7 @@ function copy_to_check_attributes(dest, src)
176176

177177
#allowable model attributes
178178
for attr in MOI.get(src, MOI.ListOfModelAttributesSet())
179-
if attr == MOI.Name() ||
179+
if attr == MOI.Name() ||
180180
attr == MOI.ObjectiveSense() ||
181181
attr isa MOI.ObjectiveFunction
182182
continue
@@ -186,7 +186,7 @@ function copy_to_check_attributes(dest, src)
186186

187187
#allowable variable attributes
188188
for attr in MOI.get(src, MOI.ListOfVariableAttributesSet())
189-
if attr == MOI.VariableName() ||
189+
if attr == MOI.VariableName() ||
190190
attr == MathOptInterface.VariablePrimalStart()
191191
continue
192192
end
@@ -196,11 +196,10 @@ function copy_to_check_attributes(dest, src)
196196
#allowable constraint types and attributes
197197
for (F, S) in MOI.get(src, MOI.ListOfConstraintTypesPresent())
198198
if !MOI.supports_constraint(dest, F, S)
199-
throw(MOI.UnsupportedConstraint{F, S}())
199+
throw(MOI.UnsupportedConstraint{F,S}())
200200
end
201-
for attr in MOI.get(src, MOI.ListOfConstraintAttributesSet{F, S}())
202-
if attr == MOI.ConstraintName() ||
203-
attr == MOI.ConstraintDualStart()
201+
for attr in MOI.get(src, MOI.ListOfConstraintAttributesSet{F,S}())
202+
if attr == MOI.ConstraintName() || attr == MOI.ConstraintDualStart()
204203
continue
205204
end
206205
throw(MOI.UnsupportedAttribute(attr))
@@ -210,7 +209,6 @@ function copy_to_check_attributes(dest, src)
210209
return nothing
211210
end
212211

213-
214212
"""
215213
Set up index map from `src` variables and constraints to `dest` variables and constraints.
216214
"""

0 commit comments

Comments
 (0)