[clang] [clang] Fix AST IgnoreUnlessSpelledInSource traversal nullptr dereference (PR #146103)

2025-06-27 Thread Jonathan Marriott via cfe-commits
https://github.com/JonathanMarriott updated https://github.com/llvm/llvm-project/pull/146103 >From 646d006e327f9d891dea5d9c334e44174a5560a3 Mon Sep 17 00:00:00 2001 From: Jon Marriott Date: Wed, 25 Jun 2025 18:04:59 +0100 Subject: [PATCH 1/3] Add check for decl nullptr to `ASTNodeTraverser::Vis

[clang] [clang][AST] Fix AST IgnoreUnlessSpelledInSource traversal nullptr dereference (PR #146103)

2025-06-27 Thread Jonathan Marriott via cfe-commits
JonathanMarriott wrote: > Thank you for the patch! Please add a release note to > "clang/docs/ReleaseNotes.rst" so users can know the improvement. Please add a > tag to the beginning of the PR title in square brackets like other PRs. E.g. > `[clang]`. Thanks, I've added a release note in what

[clang] Fix AST IgnoreUnlessSpelledInSource traversal nullptr dereference (PR #146103)

2025-06-27 Thread Jonathan Marriott via cfe-commits
https://github.com/JonathanMarriott created https://github.com/llvm/llvm-project/pull/146103 Fixes #146101, in summary dumping a `catch(...)` statement using IgnoreUnlessSpelledInSource AST traversal causes a seg fault, as the variable declaration of the catch is `nullptr`. Diagnosed the caus

[clang] Fix AST IgnoreUnlessSpelledInSource traversal nullptr dereference (PR #146103)

2025-06-27 Thread Jonathan Marriott via cfe-commits
https://github.com/JonathanMarriott ready_for_review https://github.com/llvm/llvm-project/pull/146103 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix AST IgnoreUnlessSpelledInSource traversal nullptr dereference (PR #146103)

2025-06-27 Thread Jonathan Marriott via cfe-commits
JonathanMarriott wrote: CC: @AaronBallman @Sirraide https://github.com/llvm/llvm-project/pull/146103 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix AST IgnoreUnlessSpelledInSource traversal nullptr dereference (PR #146103)

2025-06-27 Thread Jonathan Marriott via cfe-commits
https://github.com/JonathanMarriott edited https://github.com/llvm/llvm-project/pull/146103 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][AST] Fix AST IgnoreUnlessSpelledInSource traversal nullptr dereference (PR #146103)

2025-06-27 Thread Jonathan Marriott via cfe-commits
https://github.com/JonathanMarriott edited https://github.com/llvm/llvm-project/pull/146103 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits