https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69753

--- Comment #5 from Patrick Palka <ppalka at gcc dot gnu.org> ---
(In reply to Patrick Palka from comment #4)
> Is this actually bogus?
> 
> [over.call.func] says:
> 
> If the keyword this (9.3.2) is in scope and refers to class T, or a derived
> class of T, then the implied object argument is (*this). If the keyword this
> is not in scope or refers to another class, then a contrived object of type
> T becomes the implied object argument.
> 
> 
> So according to that, "auto guest = A::FromWebContents();" becomes "auto
> guest = this->A::FromWebContents();" right?
> 
> This makes "guest" dependent and so is actually "guest->As<T> ();" is
> invalid.  It has it be "guest->template As<T> ();"

(Sorry, my browser is not displaying textareas properly...)

Last line should say,

  This makes guest dependent and so guest->As<T>() has to be written as
guest->template As<T>();

Reply via email to