http://crbug.com/697235 implemented base equivalents of std::erase/std::erase_if from Library Fundamentals TS v2. These methods replace the common erase-remove idiom with shorter and less error prone code and are thus preferable. This bug is to track progress on replacing the old idiom wherever possible. References: - http://en.cppreference.com/w/cpp/experimental/lib_extensions_2#Uniform_container_erasure - http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2014/n4273
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/c1e6a51270ce12fc32415422903d2735a8455b56 commit c1e6a51270ce12fc32415422903d2735a8455b56 Author: jdoerrie <jdoerrie@chromium.org> Date: Mon Mar 27 11:04:37 2017 Use base::EraseIf in Password Form Manager As a quick follow up to http://crrev.com/2774653006 this change replaces the erase-remove idiom with base::EraseIf in password_form_manager.cc BUG= 705433 R=vabr@chromium.org Review-Url: https://codereview.chromium.org/2776943003 Cr-Commit-Position: refs/heads/master@{#459749} [modify] https://crrev.com/c1e6a51270ce12fc32415422903d2735a8455b56/components/password_manager/core/browser/password_form_manager.cc
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/0606479c7c2a17b6d20a61a3034eddd13838e722 commit 0606479c7c2a17b6d20a61a3034eddd13838e722 Author: jdoerrie <jdoerrie@chromium.org> Date: Mon Mar 27 12:43:10 2017 Refactor Password Manager to use base::EraseIf This change replaces the erase-remove idiom by calls to base::EraseIf in the Password Manager code where appropriate. BUG= 705433 R=vasilii@chromium.org Review-Url: https://codereview.chromium.org/2774653006 Cr-Commit-Position: refs/heads/master@{#459761} [modify] https://crrev.com/0606479c7c2a17b6d20a61a3034eddd13838e722/components/password_manager/core/browser/credential_manager_pending_request_task.cc [modify] https://crrev.com/0606479c7c2a17b6d20a61a3034eddd13838e722/components/password_manager/core/browser/form_fetcher_impl_unittest.cc [modify] https://crrev.com/0606479c7c2a17b6d20a61a3034eddd13838e722/components/password_manager/core/browser/http_password_store_migrator.cc [modify] https://crrev.com/0606479c7c2a17b6d20a61a3034eddd13838e722/components/password_manager/core/browser/obsolete_http_cleaner.cc [modify] https://crrev.com/0606479c7c2a17b6d20a61a3034eddd13838e722/components/password_manager/core/browser/password_manager_util.cc [modify] https://crrev.com/0606479c7c2a17b6d20a61a3034eddd13838e722/components/password_manager/core/browser/password_store.cc
Comment 1 by bugdroid1@chromium.org
, Mar 27 2017