Fix variables leaking when adding other system under transaction
This commit is contained in:
+3
@@ -165,6 +165,9 @@ class NewConstraintSystemImpl(
|
|||||||
}
|
}
|
||||||
|
|
||||||
override fun addOtherSystem(otherSystem: ConstraintStorage) {
|
override fun addOtherSystem(otherSystem: ConstraintStorage) {
|
||||||
|
otherSystem.allTypeVariables.forEach {
|
||||||
|
transactionRegisterVariable(it.value)
|
||||||
|
}
|
||||||
storage.allTypeVariables.putAll(otherSystem.allTypeVariables)
|
storage.allTypeVariables.putAll(otherSystem.allTypeVariables)
|
||||||
for ((variable, constraints) in otherSystem.notFixedTypeVariables) {
|
for ((variable, constraints) in otherSystem.notFixedTypeVariables) {
|
||||||
notFixedTypeVariables[variable] = MutableVariableWithConstraints(constraints.typeVariable, constraints.constraints)
|
notFixedTypeVariables[variable] = MutableVariableWithConstraints(constraints.typeVariable, constraints.constraints)
|
||||||
|
|||||||
Reference in New Issue
Block a user