mirror of
https://github.com/github/codeql.git
synced 2026-04-28 18:25:24 +02:00
Minor code quality improvements
This commit is contained in:
@@ -28,7 +28,7 @@ namespace Semmle.Extraction.Entities
|
||||
|
||||
public override bool Equals(object? obj) => obj != null && obj.GetType() == typeof(GeneratedLocation);
|
||||
|
||||
public static GeneratedLocation Create(Context cx) => GeneratedLocationFactory.Instance.CreateEntity(cx, typeof(GeneratedLocation), null);
|
||||
public static new GeneratedLocation Create(Context cx) => GeneratedLocationFactory.Instance.CreateEntity(cx, typeof(GeneratedLocation), null);
|
||||
|
||||
private class GeneratedLocationFactory : ICachedEntityFactory<string?, GeneratedLocation>
|
||||
{
|
||||
|
||||
@@ -20,7 +20,6 @@ namespace Semmle.Extraction.Entities
|
||||
return cx.SourceTree == null
|
||||
? GeneratedLocation.Create(cx)
|
||||
: Create(cx, Microsoft.CodeAnalysis.Location.Create(cx.SourceTree, TextSpan.FromBounds(0, 0)));
|
||||
|
||||
}
|
||||
|
||||
public override Microsoft.CodeAnalysis.Location? ReportingLocation => symbol;
|
||||
|
||||
Reference in New Issue
Block a user