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++/11847] [3.4 regression] reference does not work as template argument any more


PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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



------- Additional Comments From bangerth at dealii dot org  2003-08-07 18:48 -------
Just a further clue that this might have something to do with
two-stage name lookup: if I make the variable template
dependent, then the code compiles again. Here's an example:
---------------------------
template <typename T> struct A {
    static const T a;
};

template <const int&> class X {};

template <typename T> struct Y {
    X<A<T>::a> x;
};

template struct Y<int>;
-----------------------------------

W.


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