generator: avoid double lookup in dictionary when DeAlias is called

We can avoid a double lookup in the types dictionary here because the
method TryGetValue() was just called before.
This commit is contained in:
Andrés G. Aragoneses 2013-08-23 22:02:16 +02:00
parent 6e0efb08f2
commit 4046a4c4bd

View File

@ -213,7 +213,7 @@ namespace GtkSharp.Generation {
type = Trim (type);
IGeneratable cur_type = null;
while (types.TryGetValue (type, out cur_type) && cur_type is AliasGen) {
IGeneratable igen = types [type] as AliasGen;
IGeneratable igen = cur_type as AliasGen;
types [type] = types [igen.Name];
type = igen.Name;
}