You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When we compile with hardening enabled, there is a bounds check inside operator[]. That check is basically equivalent to index < size(). However, it doesn't get elided even though the loop condition should guarantee that the condition always holds. It seems to be elided when iterating over a span, but not a string or a vector, which makes me think the optimizer could be improved.