This is the mail archive of the gcc-bugs@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]

[Bug c++/50921] GCC cannot find dependent conversion-function-id even if there's a using declaration for it


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50921

--- Comment #1 from Johannes Schaub <schaub.johannes at googlemail dot com> 2011-10-30 13:54:21 UTC ---
Someone notified me that you can substantially reduce this to the following

template<typename T>
struct Base {
  operator int();
};

template<typename T>
struct Derived : Base<T> {
  using Base<T>::operator int;
  void f() { 
    int x = operator int(); 
    (void) x;
  }
};

int main() {
  Derived<int> d;
  d.f();
}

Same diagnostic is given.


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