mirror of
https://github.com/apple/swift-nio
synced 2026-11-24 04:37:54 +00:00
Conforms TimeAmount to AdditiveArithmetic. Motivation: TimeAmount does not support -=, +=. Sometimes it is useful to manipulate time amounts when building up a delay and if that iteration fails, we would want to delay += .milliseconds(5) to add 5 milliseconds to our delay and try again. Modifications: Conformed TimeAmount to AdditiveArithmetic: added a static zero property and required operators. Result: TimeAmount conforms to AdditiveArithmetic. Co-authored-by: Josh <jrtkski@icloud.com> Co-authored-by: Cory Benfield <lukasa@apple.com>