[Bug c++/90473] gcc does not call function in comma operator for default argument
mpolacek at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Thu Aug 8 21:40:00 GMT 2019
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90473
Marek Polacek <mpolacek at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |mpolacek at gcc dot gnu.org
--- Comment #2 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
This is where we lose the side-effect:
check_default_argument
13174 /* Avoid redundant -Wzero-as-null-pointer-constant warnings at
13175 the call sites. */
13176 if (TYPE_PTR_OR_PTRMEM_P (decl_type)
13177 && null_ptr_cst_p (arg))
13178 return nullptr_node;
Poking more...
More information about the Gcc-bugs
mailing list