🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c++
Article #2719

Re: Dependency through template use

#2719
From: David Vandevoorde
Date: Fri, 24 Nov 1995 17:24
26 lines
1277 bytes
>>>>> "MG" == Marc Girod <girod@dshp01.trs.ntc.nokia.com> writes:
[...]
MG> template <class T> class X {
MG>     T t_;
MG> };

MG> class Y;

MG> class Z {
MG>     X<Y>* x_;
MG> };
[...]

I'm pretty sure it's correct C++ under the current DWP
(and my compiler compiles it quietly). If it is a serious
problem, does a typedef help?
	class Z {
	    typedef X<Y>* Ptr_;
	    Ptr_ x_;
	};

	Daveed

[ comp.std.c++ is moderated.  Submission address: std-c++@ncar.ucar.edu.
  Contact address: std-c++-request@ncar.ucar.edu.  The moderation policy
  is summarized in http://dogbert.lbl.gov/~matt/std-c++/policy.html. ]
Technical Details
Message-ID: <VANDEVOD.95Nov23203527@avs.cs.rpi.edu>
Path: arc1-ca.pugleaf.net!engnews1.Eng.Sun.COM!taumet!clamage
References: <GIROD.95Nov23152417@dshp01.trs.ntc.nokia.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!engnews1.Eng.Sun.COM!taumet!clamage
From: vandevod@cs.rpi.edu (David Vandevoorde)
Newsgroups: comp.std.c++
Subject: Re: Dependency through template use
Date: 24 Nov 1995 17:24:33 GMT
Organization: RPI Computer Science
Approved: clamage@eng.sun.com (comp.std.c++)
Distribution: world
Message-ID: <VANDEVOD.95Nov23203527@avs.cs.rpi.edu>
References: <GIROD.95Nov23152417@dshp01.trs.ntc.nokia.com>
NNTP-Posting-Host: taumet.eng.sun.com
Content-Type: text
X-Nntp-Posting-Host: avs.cs.rpi.edu
In-Reply-To: girod@dshp01.trs.ntc.nokia.com's message of 23 Nov 1995 15:32:28 GMT
Content-Length: 393
Originator: clamage@taumet