Adds constraint.