-
Notifications
You must be signed in to change notification settings - Fork 773
Description
Running ./install.py
on macOS 10.10.5 with clang-3.4 (clang 3.4.2 fails with the following error message:
FAILED: /usr/local/bin/clang++-3.4 -stdlib=libc++ -DUSE_CLANG_COMPLETER -DYCMD_CORE_VERSION=28 -Dycm_core_EXPORTS -I/Users/rudolph/.vim/bundle/YouCompleteMe/third_party/ycmd/cpp/ycm -I/Users/rudolph/.vim/bundle/YouCompleteMe/third_party/ycmd/cpp/ycm/ClangCompleter -isystem /Users/rudolph/.vim/bundle/YouCompleteMe/third_party/ycmd/cpp/BoostParts -isystem /usr/local/Cellar/python/2.7.12/Frameworks/Python.framework/Versions/2.7/include/python2.7 -isystem ycm/../clang+llvm-4.0.0-x86_64-apple-darwin/include -nostdinc++ -isystem /usr/local/lib/llvm-3.4/include/c++/v1 -stdlib=libc++ -fcolor-diagnostics -O3 -DNDEBUG -fPIC -std=c++11 -MD -MT ycm/CMakeFiles/ycm_core.dir/IdentifierUtils.cpp.o -MF ycm/CMakeFiles/ycm_core.dir/IdentifierUtils.cpp.o.d -o ycm/CMakeFiles/ycm_core.dir/IdentifierUtils.cpp.o -c /Users/rudolph/.vim/bundle/YouCompleteMe/third_party/ycmd/cpp/ycm/IdentifierUtils.cpp
…
/Users/rudolph/.vim/bundle/YouCompleteMe/third_party/ycmd/cpp/ycm/IdentifierUtils.cpp:120:12: error: chosen constructor is explicit in copy-initialization
return {};
As far as I can see, this is an actual bug, introduced in c5ac035: the std::map
copy constructor in C++11 is explicit
, initialisation by {}
in a return
statement is thus forbidden (though g++ erroneously accepts the code).
A simple fix would be to replace the line with
return FiletypeIdentifierMap{};