Telerik® JustCode™ can suggest you to convert an if-else statement to a conditional expression where possible.
Supported: C#, VB.NET
The behavior can be controlled in JustCode Options -
JustCode / Options / Code Analysis / Hints / C#.
When "Show hint for convert if statement to conditional expression" option is checked in the options dialog,
then Telerik® JustCode™ suggests you to to convert an if-else statement to a conditional expression where possible.
To convert if statement to conditional expression
Position the caret on the condition part of an if-else statement which can be converted to a conditional expression.
Select Convert if statement to conditional expression from the VisualAid's Fixes menu.
The result is: