Skip to content

Commit

Permalink
Fix some warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
mhutch committed May 17, 2024
1 parent 8673379 commit 4550d9e
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
5 changes: 5 additions & 0 deletions MSBuildLanguageServer/MSBuildLanguageServer.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@
<RootNamespace>MonoDevelop.MSBuild.Editor.LanguageServer</RootNamespace>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<OutputType>Exe</OutputType>
<NoWarn>
$(NoWarn);
<!-- imported roslyn code triggers VS threading analyzer warnings -->
VSTHRD003;VSTHRD103;VSTHRD110;VSTHRD002
</NoWarn>
</PropertyGroup>

<ItemGroup>
Expand Down
8 changes: 4 additions & 4 deletions MSBuildLanguageServer/RequestContext.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ readonly struct RequestContext (ILspServices services, ILspLogger logger)
public ILspLogger Logger { get; } = logger;
public WellKnownLspServerKinds ServerKind => WellKnownLspServerKinds.MSBuild;

public static async Task<RequestContext> CreateAsync(
public static Task<RequestContext> CreateAsync(
bool mutatesSolutionState,
bool requiresLSPSolution,
TextDocumentIdentifier? textDocument,
Expand All @@ -32,16 +32,16 @@ public ClientCapabilities GetRequiredClientCapabilities ()

public T GetRequiredLspService<T>() where T : class, ILspService
{
return services.GetRequiredService<T>();
return Services.GetRequiredService<T>();
}

public T GetRequiredService<T>() where T : class
{
return services.GetRequiredService<T>();
return Services.GetRequiredService<T>();
}

public IEnumerable<T> GetRequiredServices<T>() where T : class
{
return services.GetRequiredServices<T>();
return Services.GetRequiredServices<T>();
}
}

0 comments on commit 4550d9e

Please sign in to comment.