https://gcc.gnu.org/g:5b8016c0c8db7a67917c2e61e1c01fa0cb5b61b3

commit r17-580-g5b8016c0c8db7a67917c2e61e1c01fa0cb5b61b3
Author: Marek Polacek <[email protected]>
Date:   Fri May 15 15:31:37 2026 -0400

    c++: remove dead code
    
    We've had this comment to remove the code since r13-963, so it seems
    it's been long enough now to go ahead and remove it.
    
    gcc/cp/ChangeLog:
    
            * constexpr.cc (cxx_eval_bare_aggregate): Remove dead code.
    
    Reviewed-by: Jason Merrill <[email protected]>

Diff:
---
 gcc/cp/constexpr.cc | 9 ---------
 1 file changed, 9 deletions(-)

diff --git a/gcc/cp/constexpr.cc b/gcc/cp/constexpr.cc
index 1fc8a56503c6..701269cd3f60 100644
--- a/gcc/cp/constexpr.cc
+++ b/gcc/cp/constexpr.cc
@@ -6883,15 +6883,6 @@ cxx_eval_bare_aggregate (const constexpr_ctx *ctx, tree 
t,
        /* This is an initializer for an empty field; now that we've
           checked that it's constant, we can ignore it.  */
        changed = true;
-      else if (index
-              && (TREE_CODE (index) == NOP_EXPR
-                  || TREE_CODE (index) == POINTER_PLUS_EXPR))
-       {
-         /* Old representation of empty bases.  FIXME remove.  */
-         gcc_checking_assert (false);
-         gcc_assert (is_empty_class (TREE_TYPE (TREE_TYPE (index))));
-         changed = true;
-       }
       else
        {
          if (TREE_CODE (type) == UNION_TYPE

Reply via email to