<div dir="ltr">Hi Greg,<div><br></div><div>Looks like a simple bug where it should have been "a | b | (c ? 0 : d)" instead of "a | b | c ? 0 : d".  Rather than rely on order of operations, which I always find confusing, I opted to just move this out into explicit initialization of the flags.</div>
<div><br></div><div>Let me know if the new code matches your original intent.</div></div>