Skip to content

Commit 946564e

Browse files
author
mikeblome
committed
removed obsolete method is_cancellation_requested from cpp files
1 parent 467fc9f commit 946564e

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

docs/parallel/concrt/codesnippet/CPP/cancellation-in-the-ppl_2.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ int wmain()
2929
while (moreToDo)
3030
{
3131
// Check for cancellation.
32-
if (is_task_cancellation_requested())
32+
if (token.is_canceled())
3333
{
3434
// TODO: Perform any necessary cleanup here...
3535

docs/parallel/concrt/codesnippet/CPP/how-to-create-a-task-that-completes-after-a-delay_2.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,11 @@ bool count_primes(unsigned int max_value, unsigned int timeout)
2626
{
2727
// Respond if the overall task is cancelled by canceling
2828
// the current task.
29-
if (is_task_cancellation_requested())
29+
if (cts.get_token().is_canceled())
3030
{
3131
cancel_current_task();
3232
}
33-
// NOTE: You can replace the calls to is_task_cancellation_requested
33+
// NOTE: You can replace the calls to is_canceled
3434
// and cancel_current_task with a call to interruption_point.
3535
// interruption_point();
3636

docs/parallel/concrt/codesnippet/CPP/how-to-create-a-task-that-completes-after-a-delay_3.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,11 +98,11 @@ bool count_primes(unsigned int max_value, unsigned int timeout)
9898
{
9999
// Respond if the overall task is cancelled by canceling
100100
// the current task.
101-
if (is_task_cancellation_requested())
101+
if (cts.get_token().is_canceled())
102102
{
103103
cancel_current_task();
104104
}
105-
// NOTE: You can replace the calls to is_task_cancellation_requested
105+
// NOTE: You can replace the calls to is_canceled
106106
// and cancel_current_task with a call to interruption_point.
107107
// interruption_point();
108108

0 commit comments

Comments
 (0)