Browse Source

Trivial fix for variable name numbering

pull/10/head
David Srbecký 15 years ago
parent
commit
7f08673210
  1. 26
      ICSharpCode.Decompiler/Ast/AstMethodBodyBuilder.cs

26
ICSharpCode.Decompiler/Ast/AstMethodBodyBuilder.cs

@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using Ast = ICSharpCode.NRefactory.CSharp;
using ICSharpCode.NRefactory.CSharp;
using Cecil = Mono.Cecil;
using Mono.Cecil;
using Mono.Cecil.Cil;
using Mono.Cecil.Rocks;
using Decompiler.ControlFlow;
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using Ast = ICSharpCode.NRefactory.CSharp;
using ICSharpCode.NRefactory.CSharp;
using Cecil = Mono.Cecil;
using Mono.Cecil;
using Mono.Cecil.Cil;
using Mono.Cecil.Rocks;
using Decompiler.ControlFlow;
namespace Decompiler
{
@ -79,8 +79,8 @@ namespace Decompiler @@ -79,8 +79,8 @@ namespace Decompiler
if (!typeNames.ContainsKey(name)) {
typeNames.Add(name, 0);
}
int count = typeNames[name];
if (count > 0) {
int count = ++(typeNames[name]);
if (count > 1) {
name += count.ToString();
}
varDef.Name = name;

Loading…
Cancel
Save