2010-05-27 Marek Safar <marek.safar@gmail.com>
[mono.git] / mcs / class / Microsoft.CSharp / Microsoft.CSharp.RuntimeBinder / CSharpBinaryOperationBinder.cs
index 2aac9a5417f5a1c79d101a24aff78e4fda377ead..72787fa3dc281370d4f4f8c9dad2597ff0eb0be8 100644 (file)
@@ -144,7 +144,7 @@ namespace Microsoft.CSharp.RuntimeBinder
                                expr = new Compiler.Binary (oper, left, right, Compiler.Location.Null);
                        }
 
-                       expr = new Compiler.Cast (new Compiler.TypeExpression (ReturnType, Compiler.Location.Null), expr);
+                       expr = new Compiler.Cast (new Compiler.TypeExpression (TypeImporter.Import (ReturnType), Compiler.Location.Null), expr);
                        
                        if ((flags & CSharpBinderFlags.CheckedContext) != 0)
                                expr = new Compiler.CheckedExpr (expr, Compiler.Location.Null);