Merge pull request #64 from knocte/master

generator: fix possible unhandled KeyNotFoundException (regression)
This commit is contained in:
Bertrand Lorentz 2013-08-25 10:32:50 -07:00
commit 654b81c9f4

View file

@ -213,8 +213,13 @@ 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;
types [type] = types [igen.Name];
IGeneratable igen = cur_type as AliasGen;
IGeneratable new_type;
if (!types.TryGetValue (igen.Name, out new_type))
new_type = null;
types [type] = new_type;
type = igen.Name;
}