Short summary of the problem
Compiling cmdstan form Github or compiling any Stan program after installing cmdstan with miniconda results in a lot of error messages. Starting with
In file included from ../tbb_2020.3/src/tbbmalloc/backend.cpp:19:
In file included from ../tbb_2020.3/src/tbbmalloc/tbbmalloc_internal.h:21:
In file included from ../tbb_2020.3/src/tbbmalloc/TypeDefinitions.h:54:
In file included from ../tbb_2020.3/src/tbbmalloc/Customize.h:21:
In file included from ../tbb_2020.3/include/tbb/tbb_stddef.h:91:
In file included from ../tbb_2020.3/include/tbb/tbb_config.h:36:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/v1/cstddef:56:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/v1/__cstddef/byte.h:14:
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/v1/__type_traits/enable_if.h:34:1: error: cannot template a using declaration
using __enable_if_t _LIBCPP_NODEBUG = typename enable_if<_Bp, _Tp>::type;
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/v1/__type_traits/enable_if.h:34:21: error: expected expression
using __enable_if_t _LIBCPP_NODEBUG = typename enable_if<_Bp, _Tp>::type;
MacOS Tahoe 26.1, cmdstanr 0.9.0, RStudio 2025.09.2, cmdstan 2.37.0. Rebuild.cmdstan() doesn’t help.
clang version 19.1.7
Target: arm64-apple-darwin25.1.0
Thread model: posix
InstalledDir: /opt/miniconda3/envs/stan/bin
GNU Make 4.4.1
Built for aarch64-apple-darwin20.0.0