[all-commits] [llvm/llvm-project] 46c8f2: Check whether EvaluatedStmt::Value is valid in Var...

Akira Hatanaka via All-commits all-commits at lists.llvm.org
Fri Jun 14 11:22:30 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 46c8f25b0a7d664d4ef3b8d6376815a877788463
      https://github.com/llvm/llvm-project/commit/46c8f25b0a7d664d4ef3b8d6376815a877788463
  Author: Akira Hatanaka <ahatanak at gmail.com>
  Date:   2024-06-14 (Fri, 14 Jun 2024)

  Changed paths:
    M clang/lib/AST/Decl.cpp

  Log Message:
  -----------
  Check whether EvaluatedStmt::Value is valid in VarDecl::hasInit (#94515)

VarDecl::isNull() doesn't tell whether the VarDecl has an initializer as
methods like ensureEvaluatedStmt can create an EvaluatedStmt even when
there isn't an initializer.

Revert e1c3e16d24b5cc097ff08e9283f53319acd3f245 as the change isn't
needed anymore with this change.

See the discussion in https://github.com/llvm/llvm-project/pull/93749.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list