- Notifications
You must be signed in to change notification settings - Fork5.2k
Commite30c200
authored
Use Task.WaitAsync in SemaphoreSlim.WaitAsync (#55262)
* Use Task.WaitAsync in SemaphoreSlim* Fix failing testThe Cancel_WaitAsync_ContinuationInvokedAsynchronously test was failing,highlighting that we were no longer invoking the continuationasynchronously from the Cancel call. But in fact we were incompletelydoing so in the past, such that we'd only force that asynchrony if notimeout was provided... if both a timeout and a token were provided,then we wouldn't. I've enhanced the test to validate both cases, andmade sure we now pass.1 parent7f88911 commite30c200
File tree
3 files changed
+56
-29
lines changed- src/libraries
- System.Private.CoreLib/src/System/Threading
- Tasks
- System.Threading/tests
3 files changed
+56
-29
lines changedLines changed: 24 additions & 24 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
701 | 701 | | |
702 | 702 | | |
703 | 703 | | |
704 | | - | |
| 704 | + | |
| 705 | + | |
| 706 | + | |
705 | 707 | | |
706 | | - | |
707 | | - | |
708 | | - | |
709 | | - | |
710 | | - | |
711 | | - | |
712 | | - | |
713 | | - | |
714 | | - | |
715 | | - | |
716 | | - | |
717 | | - | |
| 708 | + | |
| 709 | + | |
| 710 | + | |
| 711 | + | |
718 | 712 | | |
719 | | - | |
| 713 | + | |
| 714 | + | |
720 | 715 | | |
721 | | - | |
722 | | - | |
723 | | - | |
724 | | - | |
725 | | - | |
726 | | - | |
727 | | - | |
728 | | - | |
729 | | - | |
| 716 | + | |
730 | 717 | | |
731 | 718 | | |
732 | | - | |
| 719 | + | |
733 | 720 | | |
734 | 721 | | |
735 | 722 | | |
| |||
750 | 737 | | |
751 | 738 | | |
752 | 739 | | |
| 740 | + | |
| 741 | + | |
| 742 | + | |
| 743 | + | |
| 744 | + | |
| 745 | + | |
| 746 | + | |
| 747 | + | |
| 748 | + | |
| 749 | + | |
| 750 | + | |
| 751 | + | |
| 752 | + | |
753 | 753 | | |
754 | 754 | | |
755 | 755 | | |
| |||
Lines changed: 24 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
529 | 529 | | |
530 | 530 | | |
531 | 531 | | |
532 | | - | |
533 | | - | |
534 | 532 | | |
| 533 | + | |
| 534 | + | |
| 535 | + | |
535 | 536 | | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
| 541 | + | |
| 542 | + | |
| 543 | + | |
| 544 | + | |
| 545 | + | |
| 546 | + | |
| 547 | + | |
| 548 | + | |
| 549 | + | |
| 550 | + | |
| 551 | + | |
| 552 | + | |
| 553 | + | |
| 554 | + | |
| 555 | + | |
| 556 | + | |
| 557 | + | |
536 | 558 | | |
537 | 559 | | |
538 | 560 | | |
| |||
Lines changed: 8 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
49 | 49 | | |
50 | 50 | | |
51 | 51 | | |
52 | | - | |
53 | | - | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
54 | 56 | | |
55 | 57 | | |
56 | 58 | | |
| |||
60 | 62 | | |
61 | 63 | | |
62 | 64 | | |
63 | | - | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
64 | 69 | | |
65 | 70 | | |
66 | 71 | | |
| |||
0 commit comments
Comments
(0)