possibly minor optimizations and highlighting