Reporter | Vladimir Reshetnikov (nikov) |
---|---|
Created | Sep 22, 2009 1:56:15 AM |
Updated | Jan 20, 2012 7:11:55 PM |
Resolved | Jan 20, 2012 2:47:14 PM |
Priority | Normal |
Type | Feature |
Fix versions | Next |
State | Fixed |
Assignee | Evgeny Pasynkov (pasynkov) |
Subsystem | No subsystem |
Affected versions | No Affected versions |
Fixed in build | 6.5.1.2889 |
static void Foo(object x, object y) { if(x is string && y is Exception) { if(x == y) // Expression is always false, because x and y are known to be of incompatible types and cannot refer to the same object { } if(ReferenceEquals(x, y)) // Expression is always false { } } }