-
Notifications
You must be signed in to change notification settings - Fork 153
Closed
Description
Bug description
VSTHRD012 gets reported if there is a private overload of a method with a JTF parameter.
Repro steps
static class Extensions
{
public static void OnMainThread(Action action) => OnMainThread(Factory, action);
private static void OnMainThread(JoinableTaskFactory factory, Action action) => factory.Run(async delegate
{
await Factory.SwitchToMainThreadAsync();
action();
});
}From anywhere else:
Extensions.OnMainThread(() => { }) // <- this will report VSTHRD012Expected behavior
No VSTRHD012 reported
Actual behavior
VSTHRD012 gets reported.
- Version used: 17.4.27
Additional context
Changing the name of the private method to something other than the name of the public method fixes VSTHRD012