Fix calling constructors with ref and in parameters (#1728)

This commit is contained in:
James Newton-King
2018-05-29 10:46:51 +12:00
committed by GitHub
parent 42ee730f3a
commit 6dd352c490
7 changed files with 245 additions and 2 deletions
@@ -275,6 +275,13 @@ namespace Newtonsoft.Json.Utilities
: t;
}
public static Type EnsureNotByRefType(Type t)
{
return (t.IsByRef && t.HasElementType)
? t.GetElementType()
: t;
}
public static bool IsGenericDefinition(Type type, Type genericInterfaceDefinition)
{
if (!type.IsGenericType())