-
Notifications
You must be signed in to change notification settings - Fork 273
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
C/C++ front-end: accept all floating-point extensions that GCC and Clang support #8169
C/C++ front-end: accept all floating-point extensions that GCC and Clang support #8169
Conversation
@@ -217,10 +217,13 @@ hexfloat1 "0"[xX]{hexdigit}*"."{hexdigit}+[pP][+-]?{integer} | |||
hexfloat2 "0"[xX]{hexdigit}*"."[pP][+-]?{integer} | |||
hexfloat3 "0"[xX]{hexdigit}*[pP][+-]?{integer} | |||
float_suffix [fFlLiIjJ]* | |||
gcc_ext_float_suffix [wWqQ]|[dD][fFdDlL]?|"f16"|"f32"|"f64"|"f128"|"f32x"|"f64x"|"f128x" | |||
clang_ext_float_suffix [qQ]|"f16"|"F16" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe these are standardised in the C++ standards; e.g., bf16
is C++23. They are not clang extensions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
GCC and Clang support these at varying versions, and while the standard appears to specify them I wasn't able to make them work when using -std=c++23
(Clang) or /std:c++latest
(MSVC).
36f9d99
to
39da677
Compare
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## develop #8169 +/- ##
========================================
Coverage 79.68% 79.69%
========================================
Files 1681 1680 -1
Lines 195297 195294 -3
========================================
+ Hits 155625 155630 +5
+ Misses 39672 39664 -8 ☔ View full report in Codecov by Sentry. |
39da677
to
f27ca35
Compare
f27ca35
to
e1f6f9a
Compare
e1f6f9a
to
5867ffc
Compare
4735bf5
to
b7a7e38
Compare
…ang support Testing with Compiler Explorer showed that Clang supports a subset of GCC's extensions, and GCC also supports some more extensions than what we previously covered.
b7a7e38
to
bf1159f
Compare
Testing with Compiler Explorer showed that Clang supports a subset of GCC's extensions, and GCC also supports some more extensions that what we previously covered.