https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69323
--- Comment #6 from Jason Merrill <jason at gcc dot gnu.org> --- Author: jason Date: Wed Feb 24 19:55:45 2016 New Revision: 233679 URL: https://gcc.gnu.org/viewcvs?rev=233679&root=gcc&view=rev Log: PR c++/69323 - valid * pt.c (instantiate_class_template_1): Set processing_template_decl before substituting friend_type. Added: branches/gcc-5-branch/gcc/testsuite/g++.dg/template/friend61.C Modified: branches/gcc-5-branch/gcc/cp/ChangeLog branches/gcc-5-branch/gcc/cp/pt.c