diff options
| author | jpbruyere <jp.bruyere@hotmail.com> | 2016-10-18 18:03:07 +0200 |
|---|---|---|
| committer | jpbruyere <jp.bruyere@hotmail.com> | 2016-10-18 18:03:07 +0200 |
| commit | 1d86070cfe97510545b0023aba101b9516fbea15 (patch) | |
| tree | 9c4a2d413cb45182f59dd78de7dc476f7a203139 /src/CompilerServices | |
| parent | 3fc4eb5d2bbac60db4133d579b99dbdb9cf6fdaf (diff) | |
dont try to find covertion methode to object in emitted MSIL
Diffstat (limited to 'src/CompilerServices')
| -rw-r--r-- | src/CompilerServices/CompilerServices.cs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/CompilerServices/CompilerServices.cs b/src/CompilerServices/CompilerServices.cs index 96f12963..305c9a5f 100644 --- a/src/CompilerServices/CompilerServices.cs +++ b/src/CompilerServices/CompilerServices.cs @@ -362,7 +362,7 @@ namespace Crow il.Emit (OpCodes.Callvirt, tostring.Method); } else if (!sourceValueType.IsValueType) il.Emit (OpCodes.Castclass, sourceValueType); - else if (b.Source.Property.PropertyType != sourceValueType) { + else if (b.Source.Property.PropertyType != sourceValueType && b.Source.Property.PropertyType != typeof(object)) { il.Emit (OpCodes.Callvirt, CompilerServices.GetConvertMethod (b.Source.Property.PropertyType)); } else il.Emit (OpCodes.Unbox_Any, b.Source.Property.PropertyType); |