This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[wwwdocs] Document a recent C++ friend declaration change
- From: Kriang Lerdsuwanakij <lerdsuwa at users dot sourceforge dot net>
- To: <gcc-patches at gcc dot gnu dot org>
- Date: Wed, 26 Nov 2003 21:31:19 +0700 (ICT)
- Subject: [wwwdocs] Document a recent C++ friend declaration change
- Reply-to: <lerdsuwa at users dot sourceforge dot net>
Hi
This patch documents a recently added support for a kind of friend
declaration to C++ frontend in the mainline. OK?
--Kriang
diff -cpr wwwdocs-save/htdocs/gcc-3.4/changes.html wwwdocs-new/htdocs/gcc-3.4/changes.html
*** wwwdocs-save/htdocs/gcc-3.4/changes.html Tue Nov 25 22:03:53 2003
--- wwwdocs-new/htdocs/gcc-3.4/changes.html Wed Nov 26 21:22:14 2003
***************
*** 246,251 ****
--- 246,261 ----
for example. See the ISO C++ Standard Committee's <a
href="http://anubis.dkuug.dk/jtc1/sc22/wg21/docs/cwg_closed.html#209">defect
report #209.</a> for details.</li>
+
+ <li>Declaration of member functions of class templates as friends are
+ supported. For example,
+ <pre>
+ template <typename T> struct A {
+ void f();
+ };
+ class C {
+ template <typename T> friend void A<T>::f();
+ };</pre></li>
<li>You must use <code>template <></code> to introduce template
specializations, as required by the standard. For example,