Remove unnecessary casts

This commit is contained in:
Sam Harwell 2014-09-30 05:14:03 -05:00
parent d26af7c8fb
commit ed95652f60
2 changed files with 3 additions and 3 deletions

View File

@ -122,7 +122,7 @@ namespace Antlr4.Runtime.Dfa
public override AbstractEdgeMap<T> Remove(int key)
{
return ((Antlr4.Runtime.Dfa.ArrayEdgeMap<T>)Put(key, null));
return Put(key, null);
}
public override AbstractEdgeMap<T> PutAll(IEdgeMap<T> m)
@ -149,7 +149,7 @@ namespace Antlr4.Runtime.Dfa
{
SingletonEdgeMap<T> other = (SingletonEdgeMap<T>)m;
System.Diagnostics.Debug.Assert(!other.IsEmpty);
return ((Antlr4.Runtime.Dfa.ArrayEdgeMap<T>)Put(other.Key, other.Value));
return Put(other.Key, other.Value);
}
else
{

View File

@ -141,7 +141,7 @@ namespace Antlr4.Runtime.Dfa
}
if (value == null)
{
return ((Antlr4.Runtime.Dfa.SparseEdgeMap<T>)Remove(key));
return Remove(key);
}
lock (this)
{