https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66416
AK <hiraditya at msn dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |hiraditya at msn dot com --- Comment #2 from AK <hiraditya at msn dot com> --- Could it be because string::find is more optimized than string::rfind? see: https://gcc.gnu.org/legacy-ml/libstdc++/2017-01/msg00034.html