From: Richard Biener Date: Mon, 3 Feb 2025 10:27:20 +0000 (+0100) Subject: c++/79786 - bougs invocation of DATA_ABI_ALIGNMENT macro X-Git-Tag: releases/gcc-12.5.0~47 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=32ad5415b926ca25e9102309e92561c1a30aa8ff;p=thirdparty%2Fgcc.git c++/79786 - bougs invocation of DATA_ABI_ALIGNMENT macro The first argument is supposed to be a type, not a decl. PR c++/79786 gcc/cp/ * rtti.cc (emit_tinfo_decl): Fix DATA_ABI_ALIGNMENT invocation. (cherry picked from commit 6ec19825b4e72611cdbd4749feed67b61392aa81) --- diff --git a/gcc/cp/rtti.cc b/gcc/cp/rtti.cc index f5b43ec0fb2..ac2ee70df63 100644 --- a/gcc/cp/rtti.cc +++ b/gcc/cp/rtti.cc @@ -1707,7 +1707,8 @@ emit_tinfo_decl (tree decl) /* Avoid targets optionally bumping up the alignment to improve vector instruction accesses, tinfo are never accessed this way. */ #ifdef DATA_ABI_ALIGNMENT - SET_DECL_ALIGN (decl, DATA_ABI_ALIGNMENT (decl, TYPE_ALIGN (TREE_TYPE (decl)))); + SET_DECL_ALIGN (decl, DATA_ABI_ALIGNMENT (TREE_TYPE (decl), + TYPE_ALIGN (TREE_TYPE (decl)))); DECL_USER_ALIGN (decl) = true; #endif return true;