jiller / agentsmithplugin

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

Rule for plural non-Flags enums incorrectly warns in some cases #64

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
The rule "Enums that are not flags should not have plural names" warns if
the suffix is 's'.

I've come across a few enums that ended with the word 'Status'.  These
raise incorrect warnings.

Instead, a better rule might be:

Style: Not matches regular expression: .+[^u]s$

(And remove suffix condition)

Original issue reported on code.google.com by drewnoakes on 6 Jun 2008 at 10:19

GoogleCodeExporter commented 8 years ago
I think I'll add regular expression to match dialog

Original comment by forever....@gmail.com on 17 Jun 2008 at 8:47

GoogleCodeExporter commented 8 years ago
Hi,

I have a similar problem:

[Flags]
internal enum Tests
{
    Test
}

This enum raises the warning "Enums that are not flags should not have plural 
names". In fact there IS the flags attribute.

I use VS2008, R# 5.1 beta, Agent Smith for the 5.0 version.

best wishes
Susanne

Original comment by SKlem...@gmail.com on 2 Jul 2010 at 9:09