summaryrefslogtreecommitdiffstats
path: root/include/mapbox/variant_visitor.hpp
diff options
context:
space:
mode:
authorzheng_wenlong <wenlong_zheng@nexty-ele.com>2019-06-06 16:31:25 +0900
committerzheng_wenlong <wenlong_zheng@nexty-ele.com>2019-06-06 16:31:25 +0900
commit9ee98a06160ee2b234e92db70eb18e128fc76e5d (patch)
treed144be711339162d8fb8662ac868cc3677318072 /include/mapbox/variant_visitor.hpp
parent61a91b68c0c895714ea8d612fc752ad4b5cf56ef (diff)
Diffstat (limited to 'include/mapbox/variant_visitor.hpp')
-rw-r--r--include/mapbox/variant_visitor.hpp38
1 files changed, 0 insertions, 38 deletions
diff --git a/include/mapbox/variant_visitor.hpp b/include/mapbox/variant_visitor.hpp
deleted file mode 100644
index 481eb65..0000000
--- a/include/mapbox/variant_visitor.hpp
+++ /dev/null
@@ -1,38 +0,0 @@
-#ifndef MAPBOX_UTIL_VARIANT_VISITOR_HPP
-#define MAPBOX_UTIL_VARIANT_VISITOR_HPP
-
-namespace mapbox {
-namespace util {
-
-template <typename... Fns>
-struct visitor;
-
-template <typename Fn>
-struct visitor<Fn> : Fn
-{
- using type = Fn;
- using Fn::operator();
-
- visitor(Fn fn) : Fn(fn) {}
-};
-
-template <typename Fn, typename... Fns>
-struct visitor<Fn, Fns...> : Fn, visitor<Fns...>
-{
- using type = visitor;
- using Fn::operator();
- using visitor<Fns...>::operator();
-
- visitor(Fn fn, Fns... fns) : Fn(fn), visitor<Fns...>(fns...) {}
-};
-
-template <typename... Fns>
-visitor<Fns...> make_visitor(Fns... fns)
-{
- return visitor<Fns...>(fns...);
-}
-
-} // namespace util
-} // namespace mapbox
-
-#endif // MAPBOX_UTIL_VARIANT_VISITOR_HPP