diff options
author | Adrian Kummerlaender | 2015-01-21 16:55:17 +0100 |
---|---|---|
committer | Adrian Kummerlaender | 2015-01-21 16:55:17 +0100 |
commit | cb1ee55373e5efd1441664ec4e6942d4ace5e368 (patch) | |
tree | 07b29541c603d2d716627e91b39e8e03ce23e4da /src/list/operation/higher | |
parent | 611150b033340ed7433d6ba2482f86aa5655bd15 (diff) | |
download | TypeAsValue-cb1ee55373e5efd1441664ec4e6942d4ace5e368.tar TypeAsValue-cb1ee55373e5efd1441664ec4e6942d4ace5e368.tar.gz TypeAsValue-cb1ee55373e5efd1441664ec4e6942d4ace5e368.tar.bz2 TypeAsValue-cb1ee55373e5efd1441664ec4e6942d4ace5e368.tar.lz TypeAsValue-cb1ee55373e5efd1441664ec4e6942d4ace5e368.tar.xz TypeAsValue-cb1ee55373e5efd1441664ec4e6942d4ace5e368.tar.zst TypeAsValue-cb1ee55373e5efd1441664ec4e6942d4ace5e368.zip |
Implemented `Contains` in terms of `Any`
* as its name implies this _function_ simplifies checking if a specific value is contained within a given list
* updated `Map` to actually resolve the provided _function_
Diffstat (limited to 'src/list/operation/higher')
-rw-r--r-- | src/list/operation/higher/misc.h | 5 | ||||
-rw-r--r-- | src/list/operation/higher/query.h | 1 |
2 files changed, 5 insertions, 1 deletions
diff --git a/src/list/operation/higher/misc.h b/src/list/operation/higher/misc.h index 1eacaaa..feec7de 100644 --- a/src/list/operation/higher/misc.h +++ b/src/list/operation/higher/misc.h @@ -17,7 +17,10 @@ class Map { typename Previous > struct function_wrapper { - typedef Cons<Function<Current>, Previous> type; + typedef Cons< + typename Function<Current>::type, + Previous + > type; }; public: diff --git a/src/list/operation/higher/query.h b/src/list/operation/higher/query.h index 34d05cb..29f65dc 100644 --- a/src/list/operation/higher/query.h +++ b/src/list/operation/higher/query.h @@ -2,6 +2,7 @@ #define TYPEASVALUE_SRC_LIST_OPERATION_HIGHER_QUERY_H_ #include "fold.h" +#include "misc.h" #include "operation/logic.h" namespace tav { |