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
[-Wcompletion-handler] Fix a non-termination issue (#78380)
The Called-Once dataflow analysis could never terminate as a
consequence of non-monotonic update on states. States of kind Escape
can override states leading to non-monotonic update.
This fix disallows the `Escape` state to override the `Reported`
state.
rdar://119671856
// The code below was able to cause non-termination but should be
1200
+
// fixed now:
1201
+
do {
1202
+
escape(handler);
1203
+
handler(); // expected-warning{{completion handler is called twice}} expected-note{{previous call is here; set to nil to indicate it cannot be called afterwards}}
0 commit comments