diff options
| author | Maxime Coste <mawww@kakoune.org> | 2018-03-13 14:24:03 +1100 |
|---|---|---|
| committer | Maxime Coste <mawww@kakoune.org> | 2018-03-13 14:24:03 +1100 |
| commit | a480e566dc500e2aeb51b01c5afd7a48b1bd2587 (patch) | |
| tree | 76ba602d73e4e7110f10899d4844ffc3015c1a1f /src/normal.cc | |
| parent | c82bf313784c63bc2fa36b0ad55167ce14e1d05a (diff) | |
ranges: Add transform overload taking directly a pointer to member
This overload will forward to the general transform implementation
using std::mem_fn to generate a callable.
Diffstat (limited to 'src/normal.cc')
| -rw-r--r-- | src/normal.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/normal.cc b/src/normal.cc index aef3f79a..05a5246e 100644 --- a/src/normal.cc +++ b/src/normal.cc @@ -1200,7 +1200,7 @@ void select_object(Context& context, NormalParams params) { 'n', select_number }, { 'u', select_argument }, }; - auto obj_it = find(selectors | transform(std::mem_fn(&ObjectType::key)), key).base(); + auto obj_it = find(selectors | transform(&ObjectType::key), key).base(); if (obj_it != std::end(selectors)) return select_and_set_last<mode>( context, std::bind(obj_it->func, _1, _2, count, flags)); |
