This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] PR c++/51476 - ICE on PTRMEM_CST as template argument in c++11


On 12/13/2011 12:43 PM, Dodji Seketeli wrote:
+      if (TREE_CODE (expr) == PTRMEM_CST)
+	/* We don't need to test if a PTRMEM_CST is a constant value
+	   because maybe_constant_value might crash and because
+	   [temp.arg.nontype]/1 says it's not allowed as a template
+	   argument anyway.  */;

A PTRMEM_CST is already constant, and a valid template argument for a parameter of pointer to member type, we just want to leave it in that form rather than lower it to a CONSTRUCTOR.


Jason


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]