summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Aditya Kumar <appujee@google.com> 2023-10-24 17:36:53 +0000
committer Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> 2023-10-24 17:36:53 +0000
commitd83c544d8146bb2fee7a0d262b3132d423949505 (patch)
tree2827776b6e6469cabdfa24aeedbe539506943935
parentbd4cd563794401c5fbbd010dfbfa92492e82c3af (diff)
parent004bccd97cc76abb0bf597f408bd5ddbc8c1cd3a (diff)
Merge "Fix visitor" into main am: 004bccd97c
Original change: https://android-review.googlesource.com/c/platform/frameworks/native/+/2800293 Change-Id: Ib68c355fe86c10a1ec35e3d8e642185d2183c386 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
-rw-r--r--services/inputflinger/InputListener.cpp2
-rw-r--r--services/inputflinger/NotifyArgs.cpp2
-rw-r--r--services/inputflinger/reader/mapper/gestures/PropertyProvider.cpp2
3 files changed, 3 insertions, 3 deletions
diff --git a/services/inputflinger/InputListener.cpp b/services/inputflinger/InputListener.cpp
index aa55873aa5..ca5d5a11d5 100644
--- a/services/inputflinger/InputListener.cpp
+++ b/services/inputflinger/InputListener.cpp
@@ -39,7 +39,7 @@ std::list<NotifyArgs>& operator+=(std::list<NotifyArgs>& keep, std::list<NotifyA
// Helper to std::visit with lambdas.
template <typename... V>
-struct Visitor : V... {};
+struct Visitor : V... { using V::operator()...; };
// explicit deduction guide (not needed as of C++20)
template <typename... V>
Visitor(V...) -> Visitor<V...>;
diff --git a/services/inputflinger/NotifyArgs.cpp b/services/inputflinger/NotifyArgs.cpp
index 0fa47d1a7c..6a25e72b5f 100644
--- a/services/inputflinger/NotifyArgs.cpp
+++ b/services/inputflinger/NotifyArgs.cpp
@@ -190,7 +190,7 @@ NotifyPointerCaptureChangedArgs::NotifyPointerCaptureChangedArgs(
// Helper to std::visit with lambdas.
template <typename... V>
-struct Visitor : V... {};
+struct Visitor : V... { using V::operator()...; };
// explicit deduction guide (not needed as of C++20)
template <typename... V>
Visitor(V...) -> Visitor<V...>;
diff --git a/services/inputflinger/reader/mapper/gestures/PropertyProvider.cpp b/services/inputflinger/reader/mapper/gestures/PropertyProvider.cpp
index be2bfed691..69264f84ed 100644
--- a/services/inputflinger/reader/mapper/gestures/PropertyProvider.cpp
+++ b/services/inputflinger/reader/mapper/gestures/PropertyProvider.cpp
@@ -239,7 +239,7 @@ namespace {
// Helper to std::visit with lambdas.
template <typename... V>
-struct Visitor : V... {};
+struct Visitor : V... { using V::operator()...; };
// explicit deduction guide (not needed as of C++20)
template <typename... V>
Visitor(V...) -> Visitor<V...>;