Quantcast
Channel: YouTrackReSharper (RSRP) - Bug and Issue Tracker
Viewing all articles
Browse latest Browse all 106942

RSRP-288225: identify redundant conditions

$
0
0
Reporter Jakub Jiricek (jakub.jiricek@vodafone.com) Jakub Jiricek (jakub.jiricek@vodafone.com)
Created Feb 9, 2012 3:18:45 PM
Updated Feb 9, 2012 3:18:45 PM
Priority Normal
Type Feature
Fix versions No Fix versions
State Submitted
Assignee Evgeny Pasynkov (pasynkov)
Subsystem Code Analysis - Control Flow
Affected versions No Affected versions
Fixed in build No Fixed in build
in cases like
    private static string test2(int i)
    {
      return i == 1
               ? (i == 1 ? "one" : "not one")
               : (i == 1 ? "ONE" : "not ONE");
    }


it would be nice if R# would find the identical (or inverted) conditions and mark them as "always true" or "always false"

Viewing all articles
Browse latest Browse all 106942

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>