DMD supports `(double x) => *cast(ulong*) &x` and `(int y) => *cast(uint*) &y` during CTFE so there's no need for elaborate measures to determine the bitwise representation of floats and doubles in CTFE.
@n8sh created dlang/druntime pull request #2642 "Issue 19976 - Simplify std.internal.convert.toUbyte CTFE path for float and double" mentioning this issue: - Issue 19976 - Simplify std.internal.convert.toUbyte CTFE path for float and double https://github.com/dlang/druntime/pull/2642
dlang/druntime pull request #2642 "Issue 19976 - Simplify std.internal.convert.toUbyte CTFE path for float and double" was merged into master: - 29eb98cf1f43965eebb1ed17ed94a6f4c5d23f65 by Nathan Sashihara: Fix Issue 19976 - Simplify std.internal.convert.toUbyte CTFE path for float and double https://github.com/dlang/druntime/pull/2642
dlang/druntime pull request #3063 "[dmd-cxx] Backport internal.convert, toPrec, SIMD aliases." was merged into dmd-cxx: - 0e0b63ccc5dd1305e9b9eeb4859f6f6fe6f49d2a by Nathan Sashihara: Fix Issue 19976 - Simplify std.internal.convert.toUbyte CTFE path for float and double https://github.com/dlang/druntime/pull/3063