Article View: comp.std.c++
Article #1976Partial Template Specialization
From: Martin Hitz
Date: Fri, 15 Sep 1995 22:21
Date: Fri, 15 Sep 1995 22:21
33 lines
1612 bytes
1612 bytes
A while ago, Steve Clamage kindly pointed out to me that partial
template specializations where allowed by the draft standard.
Thus for a template
template<class T, int n> class X { ... };
it should be possible to explicitly specify a variant for, say,
class X<class T, 1> { ... };
where T is still a "free" formal parameter.
Although I know that most compiler don't support this feature yet,
I'am curious about the syntax of such a partial specialization
(I don't think the above example is correct).
Is anybody able to figure that out of the standard document?
Regards,
Martin Hitz
Applied Computer Science & | Email: Martin.Hitz@univie.ac.at
Information Systems | URL: http://www.pri.univie.ac.at
University of Vienna | Phone: +43-1-40103-2795
Rathausstrasse 19/4 | Secretary: +43-1-40103-2792
A-1010 Vienna (Austria, Europe) | Fax: +43-1-4066712
---
[ 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:
<MATT.95Sep15152129@physics2.Berkeley.EDU>Path:
arc1-ca.pugleaf.net!128.32.155.1!mattShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!128.32.155.1!matt From: Martin Hitz <hitz@ftp.univie.ac.at> Newsgroups: comp.std.c++ Subject: Partial Template Specialization Date: 15 Sep 1995 22:21:29 GMT Organization: Applied Computer Science and Information Systems, University Vienna Approved: matt@physics2.Berkeley.EDU (Matt Austern) Message-ID: <MATT.95Sep15152129@physics2.Berkeley.EDU> NNTP-Posting-Host: physics2.berkeley.edu