On 6/2/21 3:46 PM, Marek Polacek wrote:
On Wed, Jun 02, 2021 at 03:40:49PM -0600, Martin Sebor via Gcc-patches wrote:+ if (!gimple_call_builtin_p (stmt, BUILT_IN_NORMAL)) + { + /* See if this is a call to placement new. */ + if (!fn + || !DECL_IS_OPERATOR_NEW_P (fn) + || DECL_IS_REPLACEABLE_OPERATOR_NEW_P (fn)) + return NULL_TREE; + + tree fname = DECL_ASSEMBLER_NAME (fn); + const char *name = IDENTIFIER_POINTER (fname); + if (strcmp (name, "_ZnwmPv") // ordinary form + && strcmp (name, "_ZnamPv")) // array form + return NULL_TREE;Not a review, but you can use id_equal here and simplify things.
Okay, done. Thanks Martin
