Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/xamarin/NRefactory.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Krüger <mkrueger@xamarin.com>2014-11-05 09:53:11 +0300
committerMike Krüger <mkrueger@xamarin.com>2014-11-05 09:53:11 +0300
commit766d208da62f40cc10772e43d34b1b45a73329d6 (patch)
treefe53da6ef08f4ec1de382c8179346a2ddce6e676 /ICSharpCode.NRefactory.CSharp.Refactoring
parent170c85174d1548870b95962752d371254436004a (diff)
Fixed bug in RedundantCastIssue.
Diffstat (limited to 'ICSharpCode.NRefactory.CSharp.Refactoring')
-rw-r--r--ICSharpCode.NRefactory.CSharp.Refactoring/CodeIssues/Synced/RedundanciesInCode/RedundantCastIssue.cs2
1 files changed, 1 insertions, 1 deletions
diff --git a/ICSharpCode.NRefactory.CSharp.Refactoring/CodeIssues/Synced/RedundanciesInCode/RedundantCastIssue.cs b/ICSharpCode.NRefactory.CSharp.Refactoring/CodeIssues/Synced/RedundanciesInCode/RedundantCastIssue.cs
index 3280c50b..20fc3145 100644
--- a/ICSharpCode.NRefactory.CSharp.Refactoring/CodeIssues/Synced/RedundanciesInCode/RedundantCastIssue.cs
+++ b/ICSharpCode.NRefactory.CSharp.Refactoring/CodeIssues/Synced/RedundanciesInCode/RedundantCastIssue.cs
@@ -161,7 +161,7 @@ namespace ICSharpCode.NRefactory.CSharp.Refactoring
// TODO: Check method accessibility & other parameter match.
int count = 0;
foreach (var method in methods) {
- if (method.Parameters.Count < nArg)
+ if (method.Parameters.Count <= nArg)
continue;
var baseTypes = method.Parameters[nArg].Type.GetAllBaseTypes();
if (expectedType == method.Parameters[nArg].Type || baseTypes.Any(t => t.Equals(expectedType)))