Add some potential grammar optimizations