allthedrones / agentsmithplugin

Automatically exported from code.google.com/p/agentsmithplugin
0 stars 0 forks source link

Underscore rule exclusion not be properly applied to constants within a method. #165

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Create a class, add a single public method Test.
2. Within the test method create a System.Int32 constant named INT_CONST (const 
int INT_CONST = 42;)
3. Go to "Agent Smith Code Style Settings"->"Naming Convention Settings" and 
edit rule "Names should not have underscore character" 
4. If any constant is not apart of the Except list add it (by default this 
exception was already in this rule).
5. Return to the Test method and observe that tool-tip and the rename suggest 
both indicate that the constant should be renamed to "INTCONST"

What is the expected behavior? What do you see instead?
I expect the rule to exclude any constant whether they are in a method or 
outside of it. Creating a constant in the class scope does not appear to have 
this bug.

What version of ReSharper, Visual Studio and Windows do you use?
Windows 7 Enterprise
VS 2010 version 10.0.30319.1 RTMRel
ReSharper build 5.1.1751.8
Agent Smith Plugin v1.4.2.35472
Using C# development platform

Please provide any additional information below.

Original issue reported on code.google.com by kitoke...@yahoo.com on 4 Oct 2010 at 7:00