Skip to content

Commit

Permalink
let 'remove_redundant_constraints' return empty list
Browse files Browse the repository at this point in the history
  • Loading branch information
schillic committed Sep 28, 2024
1 parent 6e1f954 commit fa3bcd3
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/Interfaces/AbstractPolyhedron_functions.jl
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ Remove the redundant constraints of a given list of linear constraints.
linear program
### Output
The list of constraints with the redundant ones removed, or an empty set if the
The list of constraints with the redundant ones removed, or an empty list if the
constraints are infeasible.
### Notes
Expand All @@ -253,8 +253,7 @@ function remove_redundant_constraints(constraints::AbstractVector{S};
if remove_redundant_constraints!(constraints_copy; backend=backend)
return constraints_copy
else # the constraints are infeasible
N = eltype(first(constraints))
return EmptySet{N}(dim(constraints[1]))
return Vector{eltype(constraints)}(undef, 0)
end
end

Expand Down

0 comments on commit fa3bcd3

Please sign in to comment.