http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55576
Jason Merrill <jason at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |NEW Last reconfirmed| |2012-12-06 Resolution|INVALID | Ever Confirmed|0 |1 --- Comment #9 from Jason Merrill <jason at gcc dot gnu.org> 2012-12-06 16:33:09 UTC --- 3.4.5 seems clear on this point: The identifier is first looked up in the class of the object expression. If the identifier is not found, it is then looked up in the context of the entire postfix-expression and shall name a class template. So the testcase in comment 3 is valid.