diff options
author | Jb Evain <jbevain@gmail.com> | 2010-06-22 16:22:03 +0400 |
---|---|---|
committer | Jb Evain <jbevain@gmail.com> | 2010-06-22 16:22:03 +0400 |
commit | 93413c9cb92557e4cc3f0bfcb6eb7c075f5d6c01 (patch) | |
tree | 691ab143d6a9acd08060a7420360e837ee6ecd02 /mcs/class/System.Core/System.Linq/QueryableEnumerable.cs | |
parent | 7d3defbb7b56ccfae1e8bd9fa06148e0206bdb48 (diff) |
fixicate
svn path=/trunk/mcs/; revision=159331
Diffstat (limited to 'mcs/class/System.Core/System.Linq/QueryableEnumerable.cs')
-rw-r--r-- | mcs/class/System.Core/System.Linq/QueryableEnumerable.cs | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/mcs/class/System.Core/System.Linq/QueryableEnumerable.cs b/mcs/class/System.Core/System.Linq/QueryableEnumerable.cs index 2eb11c4a316..8dfe62a3eac 100644 --- a/mcs/class/System.Core/System.Linq/QueryableEnumerable.cs +++ b/mcs/class/System.Core/System.Linq/QueryableEnumerable.cs @@ -119,11 +119,14 @@ namespace System.Linq { if (enumerable != null) return enumerable.ToString (); + if (expression == null) + return base.ToString (); + var constant = expression as ConstantExpression; - if (constant != null) - return constant.ToString (); + if (constant != null && constant.Value == this) + return base.ToString (); - return base.ToString (); + return expression.ToString (); } } } |