C#: Change string.Format calls to interpolated strings

This commit is contained in:
Tamas Vajk
2024-06-27 09:20:44 +02:00
parent 4a98436884
commit 0c34b4535a
17 changed files with 58 additions and 58 deletions

View File

@@ -14,7 +14,7 @@ namespace Semmle.Extraction.CSharp.Entities
PopulateModifiers(trapFile);
ContainingType!.PopulateGenerics();
trapFile.destructors(this, string.Format("~{0}", Symbol.ContainingType.Name), ContainingType, OriginalDefinition(Context, this, Symbol));
trapFile.destructors(this, $"~{Symbol.ContainingType.Name}", ContainingType, OriginalDefinition(Context, this, Symbol));
trapFile.destructor_location(this, Location);
}

View File

@@ -63,7 +63,7 @@ namespace Semmle.Extraction.CSharp.Entities
{
if (method.MethodKind == MethodKind.ReducedExtension)
{
cx.ExtractionContext.Logger.Log(Semmle.Util.Logging.Severity.Warning, "Reduced extension method symbols should not be directly extracted.");
cx.ExtractionContext.Logger.LogWarning("Reduced extension method symbols should not be directly extracted.");
}
return OrdinaryMethodFactory.Instance.CreateEntityFromSymbol(cx, method);