[libcxx-commits] [libcxx] [libc++] Make all `__random/HEADER.h` depend on `<__math/FOO.h>` instead of `<cmath>` and use `__math::` namespace instead `std::` (PR #213084)

A. Jiang via libcxx-commits libcxx-commits at lists.llvm.org
Thu Jul 30 21:11:46 PDT 2026


Hana =?utf-8?q?Dusíková?= <hanicka at hanicka.net>
Message-ID:
In-Reply-To: <llvm.org/llvm/llvm-project/pull/213084 at github.com>


frederick-vs-ja wrote:

> > I have found some of `<random>` functionality depends on system's `math.h`
> 
> My understanding is that this shouldn't be the case, but perhaps we're doing something wrong?

IIUC what actually happened is that "some of `<random>` functionality call functions from system's `<math.h>`".

It seems possible to avoid such dependency but we choose to call some functions from the underlying C standard library implementation if possible.

https://github.com/llvm/llvm-project/pull/213084


More information about the libcxx-commits mailing list