nixprime / cpsm

A CtrlP matcher, specialized for paths.
Apache License 2.0
202 stars 19 forks source link

Experimental build fails on OSX #20

Closed eapache closed 8 years ago

eapache commented 8 years ago

Played a bit with the experimental branch on linux so far and it looks great (and definitely seens to resolve #18). However, it isn't building on my OSX machine.

In file included from /Users/eapache/.vim/bundle-local/cpsm/src/python_extension_main.cc:29:
/Users/eapache/.vim/bundle-local/cpsm/src/api.h:225:31: error: constexpr variable 'comparator' must be initialized by a constant expression
  constexpr auto comparator = [](MatchedItem const& x, MatchedItem const& y) {
                              ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/eapache/.vim/bundle-local/cpsm/src/api.h:156:15: note: in instantiation of function template specialization 'cpsm::detail::for_each_match<cpsm::PlatformPathTraits, cpsm::Utf8StringTraits, (anonymous namespace)::PyObjItem<cpsm::CtrlPItem<cpsm::StringRefItem, cpsm::FullLineMatch> >, (anonymous namespace)::PyListCtrlPMatchSource<cpsm::FullLineMatch>,
      (lambda at /Users/eapache/.vim/bundle-local/cpsm/src/python_extension_main.cc:239:9)>' requested here
      detail::for_each_match<PlatformPathTraits, Utf8StringTraits, Item>(
              ^
/Users/eapache/.vim/bundle-local/cpsm/src/python_extension_main.cc:239:9: note: in instantiation of function template specialization 'cpsm::for_each_match<(anonymous namespace)::PyObjItem<cpsm::CtrlPItem<cpsm::StringRefItem, cpsm::FullLineMatch> >, (anonymous namespace)::PyListCtrlPMatchSource<cpsm::FullLineMatch>,
      (lambda at /Users/eapache/.vim/bundle-local/cpsm/src/python_extension_main.cc:239:9)>' requested here
        DO_MATCH_WITH_MMODE(cpsm::FullLineMatch);
        ^
/Users/eapache/.vim/bundle-local/cpsm/src/python_extension_main.cc:230:9: note: expanded from macro 'DO_MATCH_WITH_MMODE'
  cpsm::for_each_match<CpsmItem<MMODE>>(                                    \
        ^

This is El Capitan with apple's clang 7.0.2.7000181. Master branch still builds fine.

nixprime commented 8 years ago

Should be fixed now (also tested on "Apple LLVM version 7.0.2 (clang-700.1.81)").