Skip to content

Add additional warning flags for dev builds not enabled by Wall or Wextra#8283

Merged
Jacobfaib merged 2 commits intoNVIDIA:mainfrom
Jacobfaib:jacobf/2026-04-02/clang-more-warnings
Apr 8, 2026
Merged

Add additional warning flags for dev builds not enabled by Wall or Wextra#8283
Jacobfaib merged 2 commits intoNVIDIA:mainfrom
Jacobfaib:jacobf/2026-04-02/clang-more-warnings

Conversation

@Jacobfaib
Copy link
Copy Markdown
Contributor

Description

This crucially also adds

  • -ftemplate-backtrace-limit=0, so CI no longer truncates template expansions in error logs.
  • -fmacro-backtrace-limit=0, similarly but for macro expansions.

Checklist

  • New or existing tests cover these changes.
  • The documentation is up to date with these changes.

@Jacobfaib Jacobfaib self-assigned this Apr 2, 2026
@github-project-automation github-project-automation bot moved this to Todo in CCCL Apr 2, 2026
@copy-pr-bot
Copy link
Copy Markdown
Contributor

copy-pr-bot bot commented Apr 2, 2026

Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually.

Contributors can view more details about this message here.

@cccl-authenticator-app cccl-authenticator-app bot moved this from Todo to In Progress in CCCL Apr 2, 2026
@Jacobfaib
Copy link
Copy Markdown
Contributor Author

/ok to test

@github-actions

This comment has been minimized.

@Jacobfaib
Copy link
Copy Markdown
Contributor Author

/ok to test

@github-actions

This comment has been minimized.

@Jacobfaib
Copy link
Copy Markdown
Contributor Author

/ok to test

@github-actions

This comment has been minimized.

@Jacobfaib
Copy link
Copy Markdown
Contributor Author

/ok to test

1 similar comment
@Jacobfaib
Copy link
Copy Markdown
Contributor Author

/ok to test

@github-actions

This comment has been minimized.

@Jacobfaib
Copy link
Copy Markdown
Contributor Author

/ok to test

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@Jacobfaib Jacobfaib marked this pull request as ready for review April 7, 2026 13:56
@Jacobfaib Jacobfaib requested review from a team as code owners April 7, 2026 13:56
@Jacobfaib Jacobfaib requested review from gevtushenko and griwes April 7, 2026 13:56
@cccl-authenticator-app cccl-authenticator-app bot moved this from In Progress to In Review in CCCL Apr 7, 2026
@Jacobfaib Jacobfaib force-pushed the jacobf/2026-04-02/clang-more-warnings branch from e6b2b8c to d8e2e14 Compare April 8, 2026 15:14
Comment on lines +81 to 82
#elif _CCCL_HAS_CPP_ATTRIBUTE(assume) && (_CCCL_STD_VER >= 2023)
# define _CCCL_ASSUME(...) [[assume(__VA_ARGS__)]]
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Q: Why shouldn't we use the attribute if the compiler supports it before C++23?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

clang warns with -Wc++23-compat. I consider this a bug, TBH, that it allows you to use [[assume]] but tells you off for doing so.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we care about the -Wc++23-compat warning?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Until we start comprehensively testing C++23, I think we should heed the warning. Our CI matrix only goes to C++20 for now.

Note this warning actually only fired due to a previous version of this PR where I also had -pedantic enabled, but that resulted in so many warnings that I turned it off and hope that someone else eventually becomes motivated enough to fix that :)

@Jacobfaib Jacobfaib force-pushed the jacobf/2026-04-02/clang-more-warnings branch from 6b62c48 to df7db2d Compare April 8, 2026 17:05
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 8, 2026

🥳 CI Workflow Results

🟩 Finished in 1h 49m: Pass: 100%/478 | Total: 5d 04h | Max: 1h 49m | Hits: 98%/555480

See results here.

@Jacobfaib Jacobfaib merged commit fea4b55 into NVIDIA:main Apr 8, 2026
494 of 497 checks passed
@github-project-automation github-project-automation bot moved this from In Review to Done in CCCL Apr 8, 2026
@Jacobfaib Jacobfaib deleted the jacobf/2026-04-02/clang-more-warnings branch April 8, 2026 19:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants