icubilla / jsonexserializer

Automatically exported from code.google.com/p/jsonexserializer
0 stars 0 forks source link

ParseTypeSpecifier incorrectly parses generic types #8

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
The ParseTypeSpecifier method in the Parser class will incorrectly parse
generic types.  This is because it calls Type.GetType(string typeName)
before checking to see if there are generic args.  If there is both a
non-generic type and a generic-type with the same name, it will find the
non-generic type, if there is only a generic type it will return null.

It should first parse the generic args.  Then append a "`" character and
the # of generic arguments to the name of the type.

Example to find:
class SomeNamespace.SomeGenericType<T, K> {
}

Use:
SomeNamespace.SomeGenericType`2

Original issue reported on code.google.com by elliott....@gmail.com on 6 Jun 2007 at 5:44

GoogleCodeExporter commented 9 years ago

Original comment by elliott....@gmail.com on 6 Jun 2007 at 5:45

GoogleCodeExporter commented 9 years ago

Original comment by elliott....@gmail.com on 16 Jun 2007 at 8:07

GoogleCodeExporter commented 9 years ago

Original comment by elliott....@gmail.com on 10 Jul 2008 at 5:01