Skip to content

Fix error operator#50

Open
Quentin62 wants to merge 19 commits into
masterfrom
fix_error_operator
Open

Fix error operator#50
Quentin62 wants to merge 19 commits into
masterfrom
fix_error_operator

Conversation

@Quentin62
Copy link
Copy Markdown
Collaborator

Fix https://www.r-project.org/nosvn/R.check/r-devel-linux-x86_64-fedora-clang/RMixtCompIO-00install.html

clang++-22 -stdlib=libc++ -std=gnu++17 -I"/data/gannet/ripley/R/R-clang/include" -DNDEBUG  -I'/data/gannet/ripley/R/test-clang/Rcpp/include' -I'/data/gannet/ripley/R/test-clang/RcppEigen/include' -I'/data/gannet/ripley/R/test-clang/BH/include' -isystem /usr/local/clang22/include -I/usr/local/clang/include   -Ilib -Ilib/LinAlg -DEIGEN_MATRIXBASE_PLUGIN=\"EigenMatrixBaseAddons.h\" -Ioptim/include -fpic  -O3 -Wall -pedantic -frtti -Wp,-D_FORTIFY_SOURCE=3 -Wno-missing-template-arg-list-after-template-kw   -c lib/Composer/ZClassInd.cpp -o lib/Composer/ZClassInd.o
In file included from lib/Composer/MixtureComposer.cpp:25:
In file included from lib/IO/IO.h:26:
In file included from /data/gannet2/ripley/Sources/LLVM/LLVM-22.1.1-Linux-X64/bin/../include/c++/v1/iostream:45:
In file included from /data/gannet2/ripley/Sources/LLVM/LLVM-22.1.1-Linux-X64/bin/../include/c++/v1/ios:228:
In file included from /data/gannet2/ripley/Sources/LLVM/LLVM-22.1.1-Linux-X64/bin/../include/c++/v1/__locale:28:
In file included from /data/gannet2/ripley/Sources/LLVM/LLVM-22.1.1-Linux-X64/bin/../include/c++/v1/string:654:
In file included from /data/gannet2/ripley/Sources/LLVM/LLVM-22.1.1-Linux-X64/bin/../include/c++/v1/string_view:975:
In file included from /data/gannet2/ripley/Sources/LLVM/LLVM-22.1.1-Linux-X64/bin/../include/c++/v1/algorithm:1875:
In file included from /data/gannet2/ripley/Sources/LLVM/LLVM-22.1.1-Linux-X64/bin/../include/c++/v1/__algorithm/make_heap.h:16:
/data/gannet2/ripley/Sources/LLVM/LLVM-22.1.1-Linux-X64/bin/../include/c++/v1/__algorithm/sift_down.h:48:23: error: type 'Eigen::MatrixBase<Eigen::Matrix<double, 1, -1>>::Iterator' does not provide a subscript operator
   48 |     __child += __comp(__first[__child], __first[__child + 1]);
      |                       ^~~~~~~ ~~~~~~~
/data/gannet2/ripley/Sources/LLVM/LLVM-22.1.1-Linux-X64/bin/../include/c++/v1/__algorithm/make_heap.h:49:12: note: in instantiation of function template specialization 'std::__sift_down<std::_ClassicAlgPolicy, true, std::__less<void, void> &, Eigen::MatrixBase<Eigen::Matrix<double, 1, -1>>::Iterator>' requested here
   49 |       std::__sift_down<_AlgPolicy, __assume_both_children>(__first, __comp_ref, __sift_down_n, __start);
      |            ^
/data/gannet2/ripley/Sources/LLVM/LLVM-22.1.1-Linux-X64/bin/../include/c++/v1/__algorithm/partial_sort.h:41:8: note: in instantiation of function template specialization 'std::__make_heap<std::_ClassicAlgPolicy, std::__less<void, void> &, Eigen::MatrixBase<Eigen::Matrix<double, 1, -1>>::Iterator>' requested here
   41 |   std::__make_heap<_AlgPolicy>(__first, __middle, __comp);
      |        ^
/data/gannet2/ripley/Sources/LLVM/LLVM-22.1.1-Linux-X64/bin/../include/c++/v1/__algorithm/partial_sort.h:65:12: note: in instantiation of function template specialization 'std::__partial_sort_impl<std::_ClassicAlgPolicy, std::__less<void, void> &, Eigen::MatrixBase<Eigen::Matrix<double, 1, -1>>::Iterator, Eigen::MatrixBase<Eigen::Matrix<double, 1, -1>>::Iterator>' requested here
   65 |       std::__partial_sort_impl<_AlgPolicy>(__first, __middle, __last, static_cast<__comp_ref_type<_Compare> >(__comp));
      |            ^
/data/gannet2/ripley/Sources/LLVM/LLVM-22.1.1-Linux-X64/bin/../include/c++/v1/__algorithm/sort.h:934:10: note: in instantiation of function template specialization 'std::__partial_sort<std::_ClassicAlgPolicy, std::__less<void, void>, Eigen::MatrixBase<Eigen::Matrix<double, 1, -1>>::Iterator, Eigen::MatrixBase<Eigen::Matrix<double, 1, -1>>::Iterator>' requested here
  934 |     std::__partial_sort<_AlgPolicy>(
      |          ^
/data/gannet2/ripley/Sources/LLVM/LLVM-22.1.1-Linux-X64/bin/../include/c++/v1/__algorithm/sort.h:945:8: note: in instantiation of function template specialization 'std::__sort_impl<std::_ClassicAlgPolicy, Eigen::MatrixBase<Eigen::Matrix<double, 1, -1>>::Iterator, std::__less<void, void>>' requested here
  945 |   std::__sort_impl<_ClassicAlgPolicy>(std::move(__first), std::move(__last), __comp);
      |        ^
/data/gannet2/ripley/Sources/LLVM/LLVM-22.1.1-Linux-X64/bin/../include/c++/v1/__algorithm/sort.h:951:8: note: in instantiation of function template specialization 'std::sort<Eigen::MatrixBase<Eigen::Matrix<double, 1, -1>>::Iterator, std::__less<void, void>>' requested here
  951 |   std::sort(__first, __last, __less<>());
      |        ^
lib/LinAlg/EigenMatrixBaseAddons.h:239:7: note: in instantiation of function template specialization 'std::sort<Eigen::MatrixBase<Eigen::Matrix<double, 1, -1>>::Iterator>' requested here
  239 |         std::sort(derived().begin(), derived().end());
      |              ^
lib/Param/ConfIntParamStat.h:70:13: note: in instantiation of member function 'Eigen::MatrixBase<Eigen::Matrix<double, 1, -1>>::sort' requested here
   70 |                                 currRow.sort();
      |                                         ^
lib/Composer/MixtureComposer.cpp:334:14: note: in instantiation of member function 'mixt::ConfIntParamStat<mixt::Vector<double>>::sampleParam' requested here
  334 |                 paramStat_.sampleParam(iteration, iterationMax);
      |                            ^
In file included from lib/Composer/MixtureComposer.cpp:25:
In file included from lib/IO/IO.h:26:

cran config:

https://www.stats.ox.ac.uk/pub/bdr/Rconfig/r-devel-linux-x86_64-fedora-clang

R-devel
x86_64 Fedora 42 Linux
clang 21.1.1 (C, C++), flang 21.1.1 (Fortran)
Timezone Europe/London
Locale en_GB.UTF-8, LC_COLLATE=C


configured with --without-lapack and config.site:
CC=clang-22
CXX="clang++-22 -stdlib=libc++"
OBJC=$CC
FC=flang-22
CFLAGS="-O3 -Wall -pedantic -Wp,-D_FORTIFY_SOURCE=3"
C17FLAGS="-O3 -Wall -pedantic -Wno-strict-prototypes -Wp,-D_FORTIFY_SOURCE=3"
FFLAGS="-O2 -pedantic"
CXXFLAGS="-O3 -Wall -pedantic -frtti -Wp,-D_FORTIFY_SOURCE=3 -Wno-missing-template-arg-list-after-template-kw"
CPPFLAGS="-isystem /usr/local/clang22/include -I/usr/local/clang/include"
LDFLAGS="-L/usr/local/clang/lib64 -L/usr/local/clang22/lib -L/usr/local/clang22/lib/x86_64-unknown-linux-gnu -L/usr/local/lib64"

@Quentin62 Quentin62 force-pushed the fix_error_operator branch 2 times, most recently from aa4ea1b to a86c161 Compare March 23, 2026 16:01
@Quentin62 Quentin62 force-pushed the fix_error_operator branch from a86c161 to 46dd3a1 Compare March 23, 2026 16:14
@Quentin62 Quentin62 force-pushed the fix_error_operator branch from d9af87f to f2fbad1 Compare March 23, 2026 17:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant