I had the same problem with a type with no namespace. Here are the genericutil changes that solved it.

@@ -36,12 +36,16 @@
         // Register a generic type that appears in a given namespace.
         //====================================================================

+        private static string Namespace(Type t)
+        {
+            return t.Namespace ?? "";
+        }
         internal static void Register(Type t) {
             Dictionary<string, List<string>> nsmap = null;
-            mapping.TryGetValue(t.Namespace, out nsmap);
+            mapping.TryGetValue(Namespace(t), out nsmap);
             if (nsmap == null) {
                 nsmap = new Dictionary<string, List<string>>();
-                mapping[t.Namespace] = nsmap;
+                mapping[Namespace(t)] = nsmap;
             }
             string basename = t.Name;
             int tick = basename.IndexOf("`");
@@ -80,7 +84,7 @@

         public static List<Type> GenericsForType(Type t) {
             Dictionary<string, List<string>> nsmap = null;
-            mapping.TryGetValue(t.Namespace, out nsmap);
+            mapping.TryGetValue(Namespace(t), out nsmap);
             if (nsmap == null) {
                 return null;
             }
@@ -99,7 +103,7 @@

             List<Type> result = new List<Type>();
             foreach (string name in names) {
-                string qname = t.Namespace + "." + name;
+                string qname = Namespace(t) + "." + name;
                 Type o = AssemblyManager.LookupType(qname);
                 if (o != null) {
                     result.Add(o);
 

Last edit: Clayton Stangeland 2014-07-11