Reporter |
|
---|---|
Created | Jun 18, 2010 8:24:41 PM |
Updated | Apr 7, 2018 11:13:02 AM |
Resolved | Apr 7, 2018 11:13:02 AM |
Subsystem | Quick Fixes |
Assignee | Alisa Afonina (alisa.afonina) |
Priority | Normal |
State | Obsolete |
Type | Bug |
Fix version | No Fix versions |
Affected versions | 5.0 |
Fixed In Version ReSharper | Undefined |
VsVersion | All Versions |
[5.1.1712]
Try create local variable 'testValue', this will suggest type "object".
If altering the if condition to...
(Also works properly if removing the condition all together).
public class Foo
{
public enum enTest { One }
public void Bar(enTest value)
{
testValue = value;
if (testValue==0)
throw new ArgumentException();
}
}
Try create local variable 'testValue', this will suggest type "object".
If altering the if condition to...
if (testValue==enTest.One)...the create local variable suggest proper type.
(Also works properly if removing the condition all together).