From c8db771e11a0e5224aa3b0766134afc8e733896e Mon Sep 17 00:00:00 2001 From: Jesse Plamondon-Willard Date: Mon, 9 Apr 2018 23:25:10 -0400 Subject: tweak message output and unit tests (#471) --- src/SMAPI.ModBuildConfig.Analyzer/NetFieldAnalyzer.cs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src/SMAPI.ModBuildConfig.Analyzer') diff --git a/src/SMAPI.ModBuildConfig.Analyzer/NetFieldAnalyzer.cs b/src/SMAPI.ModBuildConfig.Analyzer/NetFieldAnalyzer.cs index d64b1486..a9987733 100644 --- a/src/SMAPI.ModBuildConfig.Analyzer/NetFieldAnalyzer.cs +++ b/src/SMAPI.ModBuildConfig.Analyzer/NetFieldAnalyzer.cs @@ -246,9 +246,7 @@ namespace StardewModdingAPI.ModBuildConfig.Analyzer TypeInfo operandType = context.SemanticModel.GetTypeInfo(operand); if (this.IsNetType(operandType.Type) && !this.IsNetType(operandType.ConvertedType)) { - string fromTypeName = operandType.Type.Name; - string toTypeName = operandType.ConvertedType.Name; - context.ReportDiagnostic(Diagnostic.Create(this.Rules["SMAPI001"], context.Node.GetLocation(), operand, fromTypeName, toTypeName)); + context.ReportDiagnostic(Diagnostic.Create(this.Rules["SMAPI001"], context.Node.GetLocation(), operand, operandType.Type.Name, operandType.ConvertedType)); return true; } -- cgit