<p>Today at work we came across the following code (some of you might recognize it):</p>

<pre><code>#define GET_VAL( val, type ) \
    {                                                   \
        ASSERT( ( pIP + sizeof(type) ) &lt;= pMethodEnd ); \
        val = ( *((type *&amp;)(pIP))++ );                  \
    }
</code></pre>

<p>Basically we have a byte array and a pointer. The macro returns a reference to a variable of type and advance the pointer to the end of that variable.</p>

<p>It reminded me of the several times that I needed to "think like a parser" in order to understand C++ code.</p>

<p>Do you know of other code examples that caused you to stop and read it several times till you managed to grasp what it was suppose to do?</p>

C, but present in C++, I find the comma operator really obfuscates code, take this...
```
```
ihi = y[0]>y[1] ? (inhi=1,0) : (inhi=0,1);
```
```
Terse and quite elegant, but very easy to miss or misunderstand.