Context: 1.11. In the case where we wait without a timeout, the alarm variable will be false when we call Suspend(). When we are subsequently woken by a notify, the syncresult will still be "ok". Thus we will call CancelAlarm on the falsy alarm value, and that will assert. I think the call to CancelAlarm needs a guard that alarm is truthy.
Context: 1.11. In the case where we wait without a timeout, the
alarm
variable will be false when we call Suspend(). When we are subsequently woken by a notify, the syncresult will still be "ok". Thus we will call CancelAlarm on the falsy alarm value, and that will assert. I think the call to CancelAlarm needs a guard that alarm is truthy.