We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7e3c6b3 commit a248973Copy full SHA for a248973
1 file changed
src/Bridges/bridge_optimizer.jl
@@ -1757,13 +1757,19 @@ function MOI.get(
1757
end
1758
1759
1760
-function _get_variable_if_equivalent(b, x)
+function _get_variable_if_equivalent(
1761
+ b::AbstractBridgeOptimizer,
1762
+ x::VariableIndex,
1763
+)
1764
return _get_variable_if_equivalent(bridged_variable_function(b, x), x)
1765
1766
-_get_variable_if_equivalent(b, ::Nothing) = nothing
1767
+_get_variable_if_equivalent(::AbstractBridgeOptimizer, ::Nothing) = nothing
1768
-function _get_variable_if_equivalent(f::MOI.ScalarAffineFunction, x)
1769
1770
+ f::MOI.ScalarAffineFunction,
1771
+ x::MOI.VariableIndex,
1772
1773
if length(f.terms) == 1
1774
term = only(f.terms)
1775
if isone(term.coefficient)
0 commit comments