clang++ -std=c++11 -Wall -g -I/usr/include/eigen3 ellpack.cpp -o ellpack In file included from ellpack.cpp:2: In file included from /usr/include/eigen3/Eigen/Dense:1: In file included from /usr/include/eigen3/Eigen/Core:269: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/algorithm:62: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:61: /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_heap.h:220:29: error: no viable overloaded '=' *(__first + __holeIndex) = _GLIBCXX_MOVE(*(__first + __secondChild)); ~~~~~~~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_heap.h:335:9: note: in instantiation of function template specialization 'std::__adjust_heap<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, long, Eigen::Triplet, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__adjust_heap(__first, __parent, __len, _GLIBCXX_MOVE(__value), ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1669:12: note: in instantiation of function template specialization 'std::__make_heap<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__make_heap(__first, __middle, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1930:12: note: in instantiation of function template specialization 'std::__heap_select<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__heap_select(__first, __middle, __last, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1945:13: note: in instantiation of function template specialization 'std::__partial_sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__partial_sort(__first, __last, __last, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1965:9: note: in instantiation of function template specialization 'std::__introsort_loop<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, long, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__introsort_loop(__first, __last, ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:4739:12: note: in instantiation of function template specialization 'std::__sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__sort(__first, __last, __gnu_cxx::__ops::__iter_comp_iter(__comp)); ^ ellpack.cpp:19:10: note: in instantiation of function template specialization 'std::sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, (lambda at ellpack.cpp:20:15)>' requested here std::sort(triplets.begin(), triplets.end(), ^ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit copy assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const class Triplet ^ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit move assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const In file included from ellpack.cpp:2: In file included from /usr/include/eigen3/Eigen/Dense:1: In file included from /usr/include/eigen3/Eigen/Core:269: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/algorithm:62: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:61: /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_heap.h:226:29: error: no viable overloaded '=' *(__first + __holeIndex) = _GLIBCXX_MOVE(*(__first ~~~~~~~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit copy assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const class Triplet ^ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit move assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const In file included from ellpack.cpp:2: In file included from /usr/include/eigen3/Eigen/Dense:1: In file included from /usr/include/eigen3/Eigen/Core:269: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/algorithm:62: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:61: /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_heap.h:131:29: error: no viable overloaded '=' *(__first + __holeIndex) = _GLIBCXX_MOVE(*(__first + __parent)); ~~~~~~~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_heap.h:230:12: note: in instantiation of function template specialization 'std::__push_heap<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, long, Eigen::Triplet, __gnu_cxx::__ops::_Iter_comp_val<(lambda at ellpack.cpp:20:15)> >' requested here std::__push_heap(__first, __holeIndex, __topIndex, ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_heap.h:335:9: note: in instantiation of function template specialization 'std::__adjust_heap<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, long, Eigen::Triplet, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__adjust_heap(__first, __parent, __len, _GLIBCXX_MOVE(__value), ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1669:12: note: in instantiation of function template specialization 'std::__make_heap<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__make_heap(__first, __middle, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1930:12: note: in instantiation of function template specialization 'std::__heap_select<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__heap_select(__first, __middle, __last, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1945:13: note: in instantiation of function template specialization 'std::__partial_sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__partial_sort(__first, __last, __last, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1965:9: note: in instantiation of function template specialization 'std::__introsort_loop<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, long, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__introsort_loop(__first, __last, ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:4739:12: note: in instantiation of function template specialization 'std::__sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__sort(__first, __last, __gnu_cxx::__ops::__iter_comp_iter(__comp)); ^ ellpack.cpp:19:10: note: in instantiation of function template specialization 'std::sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, (lambda at ellpack.cpp:20:15)>' requested here std::sort(triplets.begin(), triplets.end(), ^ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit copy assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const class Triplet ^ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit move assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const In file included from ellpack.cpp:2: In file included from /usr/include/eigen3/Eigen/Dense:1: In file included from /usr/include/eigen3/Eigen/Core:269: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/algorithm:62: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:61: /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_heap.h:135:32: error: no viable overloaded '=' *(__first + __holeIndex) = _GLIBCXX_MOVE(__value); ~~~~~~~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit copy assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const class Triplet ^ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit move assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const In file included from ellpack.cpp:2: In file included from /usr/include/eigen3/Eigen/Dense:1: In file included from /usr/include/eigen3/Eigen/Core:269: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/algorithm:62: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:61: /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_heap.h:246:17: error: no viable overloaded '=' *__result = _GLIBCXX_MOVE(*__first); ~~~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1672:9: note: in instantiation of function template specialization 'std::__pop_heap<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__pop_heap(__first, __middle, __i, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1930:12: note: in instantiation of function template specialization 'std::__heap_select<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__heap_select(__first, __middle, __last, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1945:13: note: in instantiation of function template specialization 'std::__partial_sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__partial_sort(__first, __last, __last, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1965:9: note: in instantiation of function template specialization 'std::__introsort_loop<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, long, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__introsort_loop(__first, __last, ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:4739:12: note: in instantiation of function template specialization 'std::__sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__sort(__first, __last, __gnu_cxx::__ops::__iter_comp_iter(__comp)); ^ ellpack.cpp:19:10: note: in instantiation of function template specialization 'std::sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, (lambda at ellpack.cpp:20:15)>' requested here std::sort(triplets.begin(), triplets.end(), ^ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit copy assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const class Triplet ^ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit move assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const In file included from ellpack.cpp:2: In file included from /usr/include/eigen3/Eigen/Dense:1: In file included from /usr/include/eigen3/Eigen/Core:269: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/algorithm:62: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:61: /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_heap.h:247:7: error: no matching function for call to '__adjust_heap' std::__adjust_heap(__first, _DistanceType(0), ^~~~~~~~~~~~~~~~~~ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_heap.h:209:5: note: candidate template ignored: substitution failure [with _RandomAccessIterator = __gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, _Distance = long, _Tp = Eigen::Triplet, _Compare = __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)>] __adjust_heap(_RandomAccessIterator __first, _Distance __holeIndex, ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_heap.h:400:4: error: no matching function for call to '__pop_heap' std::__pop_heap(__first, __last, __last, __comp); ^~~~~~~~~~~~~~~ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1931:12: note: in instantiation of function template specialization 'std::__sort_heap<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__sort_heap(__first, __middle, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1945:13: note: in instantiation of function template specialization 'std::__partial_sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__partial_sort(__first, __last, __last, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1965:9: note: in instantiation of function template specialization 'std::__introsort_loop<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, long, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__introsort_loop(__first, __last, ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:4739:12: note: in instantiation of function template specialization 'std::__sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__sort(__first, __last, __gnu_cxx::__ops::__iter_comp_iter(__comp)); ^ ellpack.cpp:19:10: note: in instantiation of function template specialization 'std::sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, (lambda at ellpack.cpp:20:15)>' requested here std::sort(triplets.begin(), triplets.end(), ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_heap.h:237:5: note: candidate template ignored: substitution failure [with _RandomAccessIterator = __gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, _Compare = __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)>] __pop_heap(_RandomAccessIterator __first, _RandomAccessIterator __last, ^ In file included from ellpack.cpp:1: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/iostream:39: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/ostream:38: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/ios:40: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/char_traits.h:39: /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algobase.h:148:7: error: no matching function for call to 'swap' swap(*__a, *__b); ^~~~ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:84:11: note: in instantiation of function template specialization 'std::iter_swap<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__normal_iterator *, std::vector, std::allocator > > > >' requested here std::iter_swap(__result, __b); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1918:12: note: in instantiation of function template specialization 'std::__move_median_to_first<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__move_median_to_first(__first, __first + 1, __mid, __last - 1, ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1950:11: note: in instantiation of function template specialization 'std::__unguarded_partition_pivot<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__unguarded_partition_pivot(__first, __last, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1965:9: note: in instantiation of function template specialization 'std::__introsort_loop<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, long, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__introsort_loop(__first, __last, ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:4739:12: note: in instantiation of function template specialization 'std::__sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__sort(__first, __last, __gnu_cxx::__ops::__iter_comp_iter(__comp)); ^ ellpack.cpp:19:10: note: in instantiation of function template specialization 'std::sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, (lambda at ellpack.cpp:20:15)>' requested here std::sort(triplets.begin(), triplets.end(), ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/move.h:177:24: note: candidate template ignored: disabled by 'enable_if' [with _Tp = const Eigen::Triplet] typename enable_if<__and_, ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/move.h:202:5: note: candidate template ignored: could not match '_Tp [_Nm]' against 'const Eigen::Triplet' swap(_Tp (&__a)[_Nm], _Tp (&__b)[_Nm]) ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_pair.h:471:5: note: candidate template ignored: could not match 'pair' against 'Triplet' swap(pair<_T1, _T2>& __x, pair<_T1, _T2>& __y) ^ In file included from ellpack.cpp:2: In file included from /usr/include/eigen3/Eigen/Dense:1: In file included from /usr/include/eigen3/Eigen/Core:269: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/algorithm:62: /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1906:4: error: no matching function for call to 'iter_swap' std::iter_swap(__first, __last); ^~~~~~~~~~~~~~ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1920:19: note: in instantiation of function template specialization 'std::__unguarded_partition<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here return std::__unguarded_partition(__first + 1, __last, __first, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1950:11: note: in instantiation of function template specialization 'std::__unguarded_partition_pivot<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__unguarded_partition_pivot(__first, __last, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1965:9: note: in instantiation of function template specialization 'std::__introsort_loop<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, long, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__introsort_loop(__first, __last, ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:4739:12: note: in instantiation of function template specialization 'std::__sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__sort(__first, __last, __gnu_cxx::__ops::__iter_comp_iter(__comp)); ^ ellpack.cpp:19:10: note: in instantiation of function template specialization 'std::sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, (lambda at ellpack.cpp:20:15)>' requested here std::sort(triplets.begin(), triplets.end(), ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/algorithmfwd.h:336:5: note: candidate template ignored: substitution failure [with _FIter1 = __gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, _FIter2 = __gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >] iter_swap(_FIter1, _FIter2); ^ In file included from ellpack.cpp:2: In file included from /usr/include/eigen3/Eigen/Dense:1: In file included from /usr/include/eigen3/Eigen/Core:269: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/algorithm:62: /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1849:17: error: no viable overloaded '=' *__first = _GLIBCXX_MOVE(__val); ~~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1882:9: note: in instantiation of function template specialization 'std::__insertion_sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__insertion_sort(__first, __first + int(_S_threshold), __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1968:9: note: in instantiation of function template specialization 'std::__final_insertion_sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__final_insertion_sort(__first, __last, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:4739:12: note: in instantiation of function template specialization 'std::__sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__sort(__first, __last, __gnu_cxx::__ops::__iter_comp_iter(__comp)); ^ ellpack.cpp:19:10: note: in instantiation of function template specialization 'std::sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, (lambda at ellpack.cpp:20:15)>' requested here std::sort(triplets.begin(), triplets.end(), ^ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit copy assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const class Triplet ^ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit move assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const In file included from ellpack.cpp:1: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/iostream:39: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/ostream:38: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/ios:40: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/char_traits.h:39: /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algobase.h:548:18: error: no viable overloaded '=' *--__result = std::move(*--__last); ~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algobase.h:588:45: note: in instantiation of function template specialization 'std::__copy_move_backward::__copy_move_b *, const Eigen::Triplet *>' requested here _Category>::__copy_move_b(__first, ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algobase.h:597:24: note: in instantiation of function template specialization 'std::__copy_move_backward_a *, const Eigen::Triplet *>' requested here return _BI2(std::__copy_move_backward_a<_IsMove> ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algobase.h:668:19: note: in instantiation of function template specialization 'std::__copy_move_backward_a2 *, std::vector, std::allocator > > >, __gnu_cxx::__normal_iterator *, std::vector, std::allocator > > > >' requested here return std::__copy_move_backward_a2(std::__miter_base(__first), ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1848:8: note: in instantiation of function template specialization 'std::move_backward<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__normal_iterator *, std::vector, std::allocator > > > >' requested here _GLIBCXX_MOVE_BACKWARD3(__first, __i, __i + 1); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algobase.h:673:53: note: expanded from macro '_GLIBCXX_MOVE_BACKWARD3' #define _GLIBCXX_MOVE_BACKWARD3(_Tp, _Up, _Vp) std::move_backward(_Tp, _Up, _Vp) ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1882:9: note: in instantiation of function template specialization 'std::__insertion_sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__insertion_sort(__first, __first + int(_S_threshold), __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1968:9: note: in instantiation of function template specialization 'std::__final_insertion_sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__final_insertion_sort(__first, __last, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:4739:12: note: in instantiation of function template specialization 'std::__sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__sort(__first, __last, __gnu_cxx::__ops::__iter_comp_iter(__comp)); ^ ellpack.cpp:19:10: note: in instantiation of function template specialization 'std::sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, (lambda at ellpack.cpp:20:15)>' requested here std::sort(triplets.begin(), triplets.end(), ^ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit copy assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const class Triplet ^ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit move assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const In file included from ellpack.cpp:2: In file included from /usr/include/eigen3/Eigen/Dense:1: In file included from /usr/include/eigen3/Eigen/Core:269: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/algorithm:62: /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1827:12: error: no viable overloaded '=' *__last = _GLIBCXX_MOVE(*__next); ~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1864:7: note: in instantiation of function template specialization 'std::__unguarded_linear_insert<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Val_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__unguarded_linear_insert(__i, ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1883:9: note: in instantiation of function template specialization 'std::__unguarded_insertion_sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__unguarded_insertion_sort(__first + int(_S_threshold), __last, ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1968:9: note: in instantiation of function template specialization 'std::__final_insertion_sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__final_insertion_sort(__first, __last, __comp); ^ /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:4739:12: note: in instantiation of function template specialization 'std::__sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, __gnu_cxx::__ops::_Iter_comp_iter<(lambda at ellpack.cpp:20:15)> >' requested here std::__sort(__first, __last, __gnu_cxx::__ops::__iter_comp_iter(__comp)); ^ ellpack.cpp:19:10: note: in instantiation of function template specialization 'std::sort<__gnu_cxx::__normal_iterator *, std::vector, std::allocator > > >, (lambda at ellpack.cpp:20:15)>' requested here std::sort(triplets.begin(), triplets.end(), ^ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit copy assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const class Triplet ^ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit move assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const In file included from ellpack.cpp:2: In file included from /usr/include/eigen3/Eigen/Dense:1: In file included from /usr/include/eigen3/Eigen/Core:269: In file included from /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/algorithm:62: /usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.3.1/../../../../include/c++/6.3.1/bits/stl_algo.h:1831:15: error: no viable overloaded '=' *__last = _GLIBCXX_MOVE(__val); ~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit copy assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const class Triplet ^ /usr/include/eigen3/Eigen/src/SparseCore/SparseUtil.h:154:7: note: candidate function (the implicit move assignment operator) not viable: 'this' argument has type 'const Eigen::Triplet', but method is not marked const 13 errors generated. make: *** [Makefile:11: ellpack] Error 1