You can get even fancier with more complex bitmasks. Say, you want only events with T4 and T6 both present, T8 (pulser) definitely not present, and don't care about other triggers. That cut would be (D.evtypebits & 0x150)==0x50, or, in shift notation, (D.evtypebits & (1<8 | 1<<6 | 1<<4)) == (1<<6 | 1<<4). Bit gymnastics are fun ;)