Replies: 8 comments 4 replies
-
|
Thanks for pointing these out. Will try to address soon. In the past there were clang bugs with Wmissing-braces, so it's always been disabled for Clang development. But, I'll turn it on to try to remove at least most of the warnings. Because we treat warnings as errors we can't generally use this flag. |
Beta Was this translation helpful? Give feedback.
-
|
@terpstra, I fixed the warning for the C++26 usage (now checks __cplusplus macro, before it only checked for compiler support for the feature). It wasn't really an issue because it would only give you better diagnostics when the feature was supported, but now you won't get an annoying warning. I dug more into I could scatter macros all throughout the code to push and pop Note, if you use CMake and use the What are your thoughts? |
Beta Was this translation helpful? Give feedback.
-
|
I appreciate the c++26 fix, thanks. I don't have an opinion one way or the other wrt. Wmissing-braces. If you think it's a clang issue, though, you should file an issue against their project. Short-term, we're just using |
Beta Was this translation helpful? Give feedback.
-
|
I'm going to move this to discussions. I don't have time to submit a detailed report to the Clang team, but there is already a lot of discussion about missing braces warnings online and I'm sure the Clang team is aware of some of the issues. |
Beta Was this translation helpful? Give feedback.
-
|
I know it's a pain because it's clang's fault and not yours but I think that using push and pop diagnostics in your library is the correct solution because otherwise the user of the library is required to then have to always use |
Beta Was this translation helpful? Give feedback.
-
|
imo, it's best to add to some top level glaze header like I don't use any of the cmake files that come with glaze and I had gazilion warnings/errors first try when I tried to use it. |
Beta Was this translation helpful? Give feedback.
-
|
We're applying this patch internally to fix all the warnings: Happy to make a PR of this to upstream it if that is desirable? |
Beta Was this translation helpful? Give feedback.
-
|
Just merged in #2024, which adds "-Wmissing-braces" for tuple brace initialization that would create warnings. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Apparently glaze is using c++26 in exactly one place:
There are also 115 warnings related to "-Wmissing-braces"; for example:
Beta Was this translation helpful? Give feedback.
All reactions