[Mono-bugs] [Bug 651305] New: New rule for misused as operator

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Thu Nov 4 10:27:19 EDT 2010


https://bugzilla.novell.com/show_bug.cgi?id=651305

https://bugzilla.novell.com/show_bug.cgi?id=651305#c0


           Summary: New rule for misused as operator
    Classification: Mono
           Product: Mono: Tools
           Version: SVN
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: Gendarme
        AssignedTo: mono-bugs at lists.ximian.com
        ReportedBy: msafar at novell.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---
           Blocker: ---


Consider this

object o = null;
string a = o == null ? null : o as string;

the conditional statement is useless and can be written as with same effect

string a = o as string;

-- 
Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.


More information about the mono-bugs mailing list