Issue 133680
Summary [libc] Fixed-point types reject negative literals in constexpr context, unlike unsigned integers
Labels libc
Assignees
Reporter kr-2003
    When using fixed-point types with negative literals in a constexpr context (like static_assert), the compiler rejects them with the error "value 0.0 is outside the range of representable values of type 'unsigned _Fract'". However, the same conversion works fine in runtime code.

<img width="1415" alt="Image" src="" />

https://godbolt.org/z/9ebq1Ev1G


_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to