You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fixed a bug that lead to the leaking of Symbols in the objective function. (#37)
Prior to this fix, whenever an `EQ` constraint was added, after being
removed, it would always lead to a lingering Symbol on the `objective`.
This was caused by a single `else` keyword, which prevented both `Error`
`Symbol`s from being removed, even though neither would be needed
anymore.
I noticed this bug when I tried to repeatedly add and remove
`Constraint`s from the `Solver` over and over again, and I noticed
through debugging that, although every other member of the `Solver` kept
a steady size, the `objective` just seemed to keep growing no matter
what.
This was caused by an assymetry when removing `Error` `Symbol`s from
`EQ` constraints. This PR fixes this assimetry.
I would appreciate if this could be merged and a new version of
`kasuari` could be created, so I don't have to post my own on
`crates.io`
0 commit comments