에러 수정

This commit is contained in:
ikpil 2023-04-29 12:49:13 +09:00
parent abf52d1ec3
commit 096cfec536
1 changed files with 8 additions and 2 deletions

View File

@ -17,7 +17,10 @@ public static class Program
{
private static List<FileLocation> CreateLocations(string path)
{
List<string> list = ((IEnumerable<string>)File.ReadAllLines(path)).Where<string>((Func<string, bool>)(line => line.Contains("error CS1061: "))).ToList<string>();
List<string> list = File.ReadAllLines(path)
.Where(line => line.Contains("error CS1061: "))
.ToList();
List<FileLocation> locations = new List<FileLocation>();
foreach (string input in list)
{
@ -70,6 +73,9 @@ public static class Program
{
var locations = Program.CreateLocations("../../../../../error.log");
foreach (FileLocation location in locations.DistinctBy(x => x.Path + x.Line))
{
Change(location);
Console.WriteLine($"{location.Path}({location.Line}:{location.Column})");
}
}
}