Optimized contain parser