https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109671
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> --- There is no way for GCC to know that get_foo_by_name does not store the argument into what is returned so it warns about this case ...