[clang] Fix a crash in constant evaluation of ExtVectorElementExprs (PR #136771)

2025-04-24 Thread Akira Hatanaka via cfe-commits
https://github.com/ahatanak closed https://github.com/llvm/llvm-project/pull/136771 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix a crash in constant evaluation of ExtVectorElementExprs (PR #136771)

2025-04-23 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. https://github.com/llvm/llvm-project/pull/136771 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix a crash in constant evaluation of ExtVectorElementExprs (PR #136771)

2025-04-23 Thread Erich Keane via cfe-commits
@@ -9197,7 +9197,10 @@ bool LValueExprEvaluator::VisitExtVectorElementExpr( if (Success) { Result.setFrom(Info.Ctx, Val); -const auto *VT = E->getBase()->getType()->castAs(); +QualType BaseType = E->getBase()->getType(); +if (E->isArrow()) er

[clang] Fix a crash in constant evaluation of ExtVectorElementExprs (PR #136771)

2025-04-22 Thread Akira Hatanaka via cfe-commits
@@ -9197,7 +9197,10 @@ bool LValueExprEvaluator::VisitExtVectorElementExpr( if (Success) { Result.setFrom(Info.Ctx, Val); -const auto *VT = E->getBase()->getType()->castAs(); +QualType BaseType = E->getBase()->getType(); +if (E->isArrow()) ah

[clang] Fix a crash in constant evaluation of ExtVectorElementExprs (PR #136771)

2025-04-22 Thread Erich Keane via cfe-commits
@@ -9197,7 +9197,10 @@ bool LValueExprEvaluator::VisitExtVectorElementExpr( if (Success) { Result.setFrom(Info.Ctx, Val); -const auto *VT = E->getBase()->getType()->castAs(); +QualType BaseType = E->getBase()->getType(); +if (E->isArrow()) er

[clang] Fix a crash in constant evaluation of ExtVectorElementExprs (PR #136771)

2025-04-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Akira Hatanaka (ahatanak) Changes Handle the case where the base expression is a pointer to a vector type. rdar://149223362 --- Full diff: https://github.com/llvm/llvm-project/pull/136771.diff 2 Files Affected: - (modified) clang/lib/A

[clang] Fix a crash in constant evaluation of ExtVectorElementExprs (PR #136771)

2025-04-22 Thread Akira Hatanaka via cfe-commits
https://github.com/ahatanak created https://github.com/llvm/llvm-project/pull/136771 Handle the case where the base expression is a pointer to a vector type. rdar://149223362 >From c8df1a51efd6349c5905b337059d597d3c1d7146 Mon Sep 17 00:00:00 2001 From: Akira Hatanaka Date: Tue, 22 Apr 2025 12