77 references to Current
Consumer (1)
ConsumerWorker.cs (1)
39
}, stoppingToken, TaskCreationOptions.LongRunning, TaskScheduler.
Current
);
dotnet-svcutil-lib (1)
FrameworkFork\System.ServiceModel\Internals\System\Runtime\TaskHelpers.cs (1)
281
return (TaskScheduler.
Current
== TaskScheduler.Default) &&
Microsoft.CodeAnalysis.Analyzers (1)
src\roslyn\src\Dependencies\Threading\ParallelExtensions.NetFramework.cs (1)
87
private static TaskScheduler EffectiveTaskScheduler(ParallelOptions options) => options.TaskScheduler ?? TaskScheduler.
Current
;
Microsoft.CodeAnalysis.AnalyzerUtilities (1)
src\roslyn\src\Dependencies\Threading\ParallelExtensions.NetFramework.cs (1)
87
private static TaskScheduler EffectiveTaskScheduler(ParallelOptions options) => options.TaskScheduler ?? TaskScheduler.
Current
;
Microsoft.CodeAnalysis.CodeStyle (1)
src\roslyn\src\Dependencies\Threading\ParallelExtensions.NetFramework.cs (1)
87
private static TaskScheduler EffectiveTaskScheduler(ParallelOptions options) => options.TaskScheduler ?? TaskScheduler.
Current
;
Microsoft.CodeAnalysis.ResxSourceGenerator (1)
src\roslyn\src\Dependencies\Threading\ParallelExtensions.NetFramework.cs (1)
87
private static TaskScheduler EffectiveTaskScheduler(ParallelOptions options) => options.TaskScheduler ?? TaskScheduler.
Current
;
Microsoft.JSInterop (3)
Infrastructure\DotNetDispatcher.cs (3)
118
task.ContinueWith(t => EndInvokeDotNetAfterTask(t, jsRuntime, invocationInfo), TaskScheduler.
Current
);
123
valueTaskResult.AsTask().ContinueWith(t => EndInvokeDotNetAfterTask(t, jsRuntime, invocationInfo), TaskScheduler.
Current
);
131
innerTask!.ContinueWith(t => EndInvokeDotNetAfterTask(t, jsRuntime, invocationInfo), TaskScheduler.
Current
);
OrderProcessor (1)
OrderProcessingWorker.cs (1)
43
}, stoppingToken, TaskCreationOptions.LongRunning, TaskScheduler.
Current
);
Roslyn.Diagnostics.Analyzers (1)
src\roslyn\src\Dependencies\Threading\ParallelExtensions.NetFramework.cs (1)
87
private static TaskScheduler EffectiveTaskScheduler(ParallelOptions options) => options.TaskScheduler ?? TaskScheduler.
Current
;
System.Net.Http (1)
System\Net\Http\SocketsHttpHandler\Http3Connection.cs (1)
497
}, CancellationToken.None, TaskContinuationOptions.ExecuteSynchronously, TaskScheduler.
Current
);
System.Private.CoreLib (47)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\CompilerServices\YieldAwaitable.cs (2)
95
TaskScheduler scheduler = TaskScheduler.
Current
;
136
TaskScheduler scheduler = TaskScheduler.
Current
;
src\runtime\src\libraries\System.Private.CoreLib\src\System\Threading\Tasks\Sources\ManualResetValueTaskSourceCore.cs (1)
158
TaskScheduler ts = TaskScheduler.
Current
;
src\runtime\src\libraries\System.Private.CoreLib\src\System\Threading\Tasks\Task.cs (17)
1060
Start(TaskScheduler.
Current
);
1145
InternalRunSynchronously(TaskScheduler.
Current
, waitForCompletion: true);
2464
log.TaskStarted(TaskScheduler.
Current
.Id, 0, this.Id);
2518
log.TaskCompleted(TaskScheduler.
Current
.Id, 0, this.Id, IsFaulted);
3819
return ContinueWith(continuationAction, TaskScheduler.
Current
, default, TaskContinuationOptions.None);
3841
return ContinueWith(continuationAction, TaskScheduler.
Current
, cancellationToken, TaskContinuationOptions.None);
3901
return ContinueWith(continuationAction, TaskScheduler.
Current
, default, continuationOptions);
3997
return ContinueWith(continuationAction, state, TaskScheduler.
Current
, default, TaskContinuationOptions.None);
4020
return ContinueWith(continuationAction, state, TaskScheduler.
Current
, cancellationToken, TaskContinuationOptions.None);
4082
return ContinueWith(continuationAction, state, TaskScheduler.
Current
, default, continuationOptions);
4182
return ContinueWith(continuationFunction, TaskScheduler.
Current
, default,
4211
return ContinueWith(continuationFunction, TaskScheduler.
Current
, cancellationToken, TaskContinuationOptions.None);
4277
return ContinueWith(continuationFunction, TaskScheduler.
Current
, default, continuationOptions);
4382
return ContinueWith(continuationFunction, state, TaskScheduler.
Current
, default,
4412
return ContinueWith(continuationFunction, state, TaskScheduler.
Current
, cancellationToken, TaskContinuationOptions.None);
4480
return ContinueWith(continuationFunction, state, TaskScheduler.
Current
, default, continuationOptions);
4688
log.AwaitTaskContinuationScheduled(TaskScheduler.
Current
.Id, CurrentId ?? 0, continuationTask.Id);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Threading\Tasks\Task_T.cs (12)
629
return ContinueWith(continuationAction, TaskScheduler.
Current
, default, TaskContinuationOptions.None);
652
return ContinueWith(continuationAction, TaskScheduler.
Current
, cancellationToken, TaskContinuationOptions.None);
713
return ContinueWith(continuationAction, TaskScheduler.
Current
, default, continuationOptions);
810
return ContinueWith(continuationAction, state, TaskScheduler.
Current
, default, TaskContinuationOptions.None);
834
return ContinueWith(continuationAction, state, TaskScheduler.
Current
, cancellationToken, TaskContinuationOptions.None);
897
return ContinueWith(continuationAction, state, TaskScheduler.
Current
, default, continuationOptions);
998
return ContinueWith(continuationFunction, TaskScheduler.
Current
, default, TaskContinuationOptions.None);
1027
return ContinueWith(continuationFunction, TaskScheduler.
Current
, cancellationToken, TaskContinuationOptions.None);
1099
return ContinueWith(continuationFunction, TaskScheduler.
Current
, default, continuationOptions);
1212
return ContinueWith(continuationFunction, state, TaskScheduler.
Current
, default, TaskContinuationOptions.None);
1243
return ContinueWith(continuationFunction, state, TaskScheduler.
Current
, cancellationToken, TaskContinuationOptions.None);
1319
return ContinueWith(continuationFunction, state, TaskScheduler.
Current
, default, continuationOptions);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Threading\Tasks\TaskFactory.cs (7)
42
private TaskScheduler DefaultScheduler => m_defaultScheduler ?? TaskScheduler.
Current
;
70
/// cref="TaskScheduler.
Current
">TaskScheduler.Current</see>).
90
/// cref="TaskScheduler.
Current
">TaskScheduler.Current</see>).
114
/// cref="TaskScheduler.
Current
">TaskScheduler.Current</see>).
145
/// cref="TaskScheduler.
Current
">TaskScheduler.Current</see>).
189
/// cref="TaskScheduler.
Current
">TaskScheduler.Current</see>).
233
/// If null, <see cref="TaskScheduler.
Current
">TaskScheduler.Current</see>
src\runtime\src\libraries\System.Private.CoreLib\src\System\Threading\Tasks\TaskFactory_T.cs (7)
39
private TaskScheduler DefaultScheduler => m_defaultScheduler ?? TaskScheduler.
Current
;
65
/// cref="TaskScheduler.
Current
">TaskScheduler.Current</see>).
85
/// cref="TaskScheduler.
Current
">TaskScheduler.Current</see>).
109
/// cref="TaskScheduler.
Current
">TaskScheduler.Current</see>).
140
/// cref="TaskScheduler.
Current
">TaskScheduler.Current</see>).
184
/// cref="TaskScheduler.
Current
">TaskScheduler.Current</see>).
213
/// If null, <see cref="TaskScheduler.
Current
">TaskScheduler.Current</see>
src\runtime\src\libraries\System.Private.CoreLib\src\System\Threading\Tasks\TaskScheduler.cs (1)
298
/// When not called from within a task, <see cref="
Current
"/> will return the <see cref="Default"/> scheduler.
System.Runtime.InteropServices.JavaScript (3)
System\Runtime\InteropServices\JavaScript\Marshaling\JSMarshalerArgument.Task.cs (3)
221
task.ContinueWith(Complete, taskHolder, TaskScheduler.
Current
);
307
task.ContinueWith(Complete, taskHolder, TaskScheduler.
Current
);
386
task.ContinueWith(Complete, new HolderAndMarshaler<T>(taskHolder, marshaler), TaskScheduler.
Current
);
System.ServiceModel.Primitives (1)
Internals\System\Runtime\TaskHelpers.cs (1)
442
return (TaskScheduler.
Current
== TaskScheduler.Default) &&
System.Threading.Channels (2)
System\Threading\Channels\AsyncOperation.cs (2)
251
if (RunContinuationsAsynchronously || ts != TaskScheduler.
Current
)
343
ts = TaskScheduler.
Current
;
System.Threading.Tasks.Parallel (12)
System\Threading\Tasks\Parallel.cs (11)
66
internal TaskScheduler EffectiveTaskScheduler => _scheduler ?? TaskScheduler.
Current
;
223
ParallelEtwProvider.Log.ParallelInvokeBegin(TaskScheduler.
Current
.Id, Task.CurrentId ?? 0,
362
ParallelEtwProvider.Log.ParallelInvokeEnd(TaskScheduler.
Current
.Id, Task.CurrentId ?? 0, forkJoinContextID);
968
ParallelEtwProvider.Log.ParallelLoopBegin(TaskScheduler.
Current
.Id, Task.CurrentId ?? 0,
1005
ParallelEtwProvider.Log.ParallelFork(TaskScheduler.
Current
.Id, Task.CurrentId ?? 0, forkJoinContextID);
1105
ParallelEtwProvider.Log.ParallelJoin(TaskScheduler.
Current
.Id, Task.CurrentId ?? 0, forkJoinContextID);
1150
ParallelEtwProvider.Log.ParallelLoopEnd(TaskScheduler.
Current
.Id, Task.CurrentId ?? 0, forkJoinContextID, long.CreateTruncating(nTotalIterations));
2535
ParallelEtwProvider.Log.ParallelLoopBegin(TaskScheduler.
Current
.Id, Task.CurrentId ?? 0,
2596
ParallelEtwProvider.Log.ParallelFork(TaskScheduler.
Current
.Id, Task.CurrentId ?? 0, forkJoinContextID);
2741
ParallelEtwProvider.Log.ParallelJoin(TaskScheduler.
Current
.Id, Task.CurrentId ?? 0, forkJoinContextID);
2789
ParallelEtwProvider.Log.ParallelLoopEnd(TaskScheduler.
Current
.Id, Task.CurrentId ?? 0, forkJoinContextID, 0);
System\Threading\Tasks\TaskReplicator.cs (1)
127
_scheduler = options.TaskScheduler ?? TaskScheduler.
Current
;