Skip to content
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

clang-tidy crash #68412

Closed
svdschoot-wefabricate opened this issue Oct 6, 2023 · 0 comments · Fixed by #68510
Closed

clang-tidy crash #68412

svdschoot-wefabricate opened this issue Oct 6, 2023 · 0 comments · Fixed by #68510
Labels
clang:dataflow Clang Dataflow Analysis framework - https://clang.llvm.org/docs/DataFlowAnalysisIntro.html clang-tidy crash Prefer [crash-on-valid] or [crash-on-invalid]

Comments

@svdschoot-wefabricate
Copy link

svdschoot-wefabricate commented Oct 6, 2023

Got a segmentation fault during bugprone-unchecked-optional-access using clang-tidy version 17.0.2.
Full output: error.log

@PiotrZSL PiotrZSL added the clang:dataflow Clang Dataflow Analysis framework - https://clang.llvm.org/docs/DataFlowAnalysisIntro.html label Oct 6, 2023
@EugeneZelenko EugeneZelenko added the crash Prefer [crash-on-valid] or [crash-on-invalid] label Oct 7, 2023
jcsxky added a commit that referenced this issue Oct 21, 2023
…68510)

`getStorageLocation` may return `nullptr` and this will produce crash
when use `cast`, use `dyn_cast_or_null` instead. I test it locally using
[FTXUI](https://github.com/ArthurSonzogni/FTXUI) and it may be the cause
of issue [issue](#68412), but
I am not sure.

Co-authored-by: huqizhi <huqizhi@836744285@qq.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clang:dataflow Clang Dataflow Analysis framework - https://clang.llvm.org/docs/DataFlowAnalysisIntro.html clang-tidy crash Prefer [crash-on-valid] or [crash-on-invalid]
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants