Skip to content

Commit 94b940f

Browse files
committed
Remove fallback
1 parent 7f5f8a4 commit 94b940f

File tree

1 file changed

+6
-13
lines changed

1 file changed

+6
-13
lines changed

src/attributes.jl

Lines changed: 6 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3281,12 +3281,10 @@ with a constraint.
32813281
## Relationship to `ConstraintDual`
32823282
32833283
In most cases, the value of this attribute is equivalent to
3284-
[`ConstraintDual`](@ref), and querying the value of [`LagrangeMultiplier`](@ref)
3285-
will fallback to querying the value of [`ConstraintDual`](@ref).
3284+
[`ConstraintDual`](@ref).
32863285
3287-
The attribute values differ in one important case.
3288-
3289-
When there is a [`VectorNonlinearOracle`](@ref) constraint of the form:
3286+
The attribute values differ in one important case. When there is a
3287+
[`VectorNonlinearOracle`](@ref) constraint of the form:
32903288
```math
32913289
x \\in VectorNonlinearOracle
32923290
```
@@ -3321,21 +3319,16 @@ MOI.get(::Optimizer, ::MOI.LagrangeMultiplier, ::MOI.ConstraintIndex)
33213319
```
33223320
They should not implement [`set`](@ref) or [`supports`](@ref).
33233321
3322+
Solvers should implement [`LagrangeMultiplier`](@ref) only if they also
3323+
implement the [`ConstraintDual`](@ref), and only if if the two values are
3324+
different.
33243325
"""
33253326
struct LagrangeMultiplier <: AbstractConstraintAttribute
33263327
result_index::Int
33273328

33283329
LagrangeMultiplier(result_index::Int = 1) = new(result_index)
33293330
end
33303331

3331-
function get_fallback(
3332-
model::ModelLike,
3333-
attr::LagrangeMultiplier,
3334-
ci::ConstraintIndex,
3335-
)
3336-
return get(model, ConstraintDual(attr.result_index), ci)
3337-
end
3338-
33393332
"""
33403333
LagrangeMultiplierStart()
33413334

0 commit comments

Comments
 (0)