https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114220
--- Comment #2 from Дилян Палаузов <dilyan.palauzov at aegee dot org> --- Is my reading correct, that the warning is triggered, when a function receives as parameter a reference to a temporary and returns a reference? If this is the only criterion, then it is a wrong assumption, that both references are somehow related.