Changeset 246826 in webkit
- Timestamp:
- Jun 25, 2019 7:00:47 PM (5 years ago)
- Location:
- trunk/Source/WTF
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WTF/ChangeLog
r246809 r246826 1 2019-06-25 Sam Weinig <weinig@apple.com> 2 3 Experiment with simple structured bindings use 4 https://bugs.webkit.org/show_bug.cgi?id=198905 5 6 Reviewed by Darin Adler. 7 8 * wtf/URLHelpers.cpp: 9 (WTF::URLHelpers::mapHostNames): 10 Simplify code using c++ structured bindings (https://en.cppreference.com/w/cpp/language/structured_binding) 11 to see if all the platforms will work with it. 12 1 13 2019-06-25 Adam Barth <abarth@webkit.org> 2 14 -
trunk/Source/WTF/wtf/URLHelpers.cpp
r245234 r246826 730 730 String result = string; 731 731 while (!hostNameRanges->isEmpty()) { 732 unsigned location, length; 733 String mappedHostName; 734 std::tie(location, length, mappedHostName) = hostNameRanges->takeLast(); 732 auto [location, length, mappedHostName] = hostNameRanges->takeLast(); 735 733 result = result.replace(location, length, mappedHostName); 736 734 }
Note: See TracChangeset
for help on using the changeset viewer.