Conditional operator always replaceable by if/else?
<p>Until now I was thinking the conditional operator <code>int a = b == 2 ? x1 : x2;</code> is always replaceable by an if/else statement.</p>

<pre><code>int a;
if (b == 2)
  a = x1;
else
  a = x2;
</code></pre>

<p>And the choice between one of the two is always a matter of taste. Today I was working with a task where a reference would be useful if I could write:</p>

<pre><code>int&amp; a;
if (b == 2)
  a = x1;
else
  a = x2;
</code></pre>

<p>This is not allowed and I tried the initialization of the reference with the conditional operator. This was working and I came to realize, that the conditional operator is not always replaceable by an if/else statement.</p>

<p>Am I right with this conclusion?</p>
