<div dir="ltr">
<div>I dont like to write:<br>if ( !('x' in obj) &&  !('y' in obj) ) {<br></div><div style="text-decoration-style:initial;text-decoration-color:initial">

<div style="text-decoration-style:initial;text-decoration-color:initial">     doit()</div></div><div style="text-decoration-style:initial;text-decoration-color:initial">}</div><div style="text-decoration-style:initial;text-decoration-color:initial"><br></div><div style="text-decoration-style:initial;text-decoration-color:initial">I was even tempted to write it that way:</div>

<div style="text-decoration-style:initial;text-decoration-color:initial">if (<span style="text-decoration-style:initial;text-decoration-color:initial;background-color:rgb(255,255,255);float:none;display:inline">'x' in<span> </span><span style="text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">obj</span><span> </span></span><span style="background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><span> </span></span><span style="background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">|| </span><span> </span><span style="text-decoration-style:initial;text-decoration-color:initial;background-color:rgb(255,255,255);float:none;display:inline">'y' in obj</span>) { } else {</div><div style="text-decoration-style:initial;text-decoration-color:initial">     doit()</div><div style="text-decoration-style:initial;text-decoration-color:initial">}</div><br style="text-decoration-style:initial;text-decoration-color:initial" clear="all">What about a !in operator to write it like this?<br class="gmail-m_5002175661530821199gmail-Apple-interchange-newline" style="text-decoration-style:initial;text-decoration-color:initial">



<div><div style="text-decoration-style:initial;text-decoration-color:initial">if (<span style="text-decoration-style:initial;text-decoration-color:initial;background-color:rgb(255,255,255);float:none;display:inline">'x' !in<span> </span><span style="text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">obj</span><span> </span></span><span style="background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><span> </span></span><span style="background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">&& </span><span style="background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><span> </span></span><span style="text-decoration-style:initial;text-decoration-color:initial;background-color:rgb(255,255,255);float:none;display:inline">'y' !in obj</span>) {</div><div style="text-decoration-style:initial;text-decoration-color:initial">

<div style="text-decoration-style:initial;text-decoration-color:initial">     doit()</div></div><div style="text-decoration-style:initial;text-decoration-color:initial">}</div></div>

<br></div>