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

c++/9765: typedefs in base class passed as a template patameter not resolved


>Number:         9765
>Category:       c++
>Synopsis:       typedefs in base class passed as a template patameter not resolved
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Feb 19 23:26:00 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator:     Anton Povarov (i.e. myself)
>Release:        g++ (GCC) 3.2 20020903 (Red Hat Linux 8.0 3.2-7)
>Organization:
>Environment:

>Description:
consider the following code
test_typedef.cc
-------
struct Test {
	typedef int my_type;
};

template <class T> struct A : public T {
	A() {
		my_type a; // it's line 7
	}
};
----------
Compiler says:
test_typedef.cc: In constructor `A<T>::A()':
test_typedef.cc:7: parse error before `;' token
>How-To-Repeat:
just compile with g++ no additional options needed
>Fix:
:)
>Release-Note:
>Audit-Trail:
>Unformatted:


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