Skip to content

Commit

Permalink
Update ConstraintProgrammingExtensions.jl
Browse files Browse the repository at this point in the history
  • Loading branch information
dourouc05 committed Feb 24, 2021
1 parent 8a80312 commit e9470e6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/ConstraintProgrammingExtensions.jl
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ struct BinPacking{T <: Real} <: MOI.AbstractVectorSet

function BinPacking(n_bins::Int, n_items::Int, weights::Vector{T}) where T <: Real
@assert n_items == length(weights)
return BinPacking{T}(n_bins, n_items, weights)
return new{T}(n_bins, n_items, weights)
end
end

Expand Down Expand Up @@ -285,7 +285,7 @@ struct FixedCapacityBinPacking{T <: Real} <: MOI.AbstractVectorSet
function FixedCapacityBinPacking(n_bins::Int, n_items::Int, weights::Vector{T}, capacities::Vector{T}) where T <: Real
@assert n_items == length(weights)
@assert n_bins == length(capacities)
return FixedCapacityBinPacking{T}(n_bins, n_items, weights)
return new{T}(n_bins, n_items, weights)
end
end

Expand Down Expand Up @@ -328,7 +328,7 @@ struct VariableCapacityBinPacking{T <: Real} <: MOI.AbstractVectorSet

function VariableCapacityBinPacking(n_bins::Int, n_items::Int, weights::Vector{T}) where T <: Real
@assert n_items == length(weights)
return VariableCapacityBinPacking{T}(n_bins, n_items, weights)
return new{T}(n_bins, n_items, weights)
end
end

Expand Down

2 comments on commit e9470e6

@dourouc05
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/30779

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.0.4 -m "<description of version>" e9470e6d244105ba303500b90e23689e31be970f
git push origin v0.0.4

Please sign in to comment.