r267236 - in /trunk/libstdc++-v3: ChangeLog src...

redi@gcc.gnu.org redi@gcc.gnu.org
Tue Dec 18 15:52:00 GMT 2018


Author: redi
Date: Tue Dec 18 15:52:37 2018
New Revision: 267236

URL: https://gcc.gnu.org/viewcvs?rev=267236&root=gcc&view=rev
Log:
Micro-optimization to avoid creating temporary path

Now that path::operator/=(basic_string_view<value_type>) works directly
from the string argument, instead of constructing a temporary path from
the string, it's potentially more efficient to do 'path(x) /= s' instead
of 'x / s'. This changes the only relevant place in the library.

	* src/filesystem/std-dir.cc (filesystem::_Dir::advance): Append
	string to lvalue to avoid creating temporary path.

Modified:
    trunk/libstdc++-v3/ChangeLog
    trunk/libstdc++-v3/src/filesystem/std-dir.cc



More information about the Libstdc++-cvs mailing list