2003-12-26 Guilhem Lavaux <guilhem@kaffe.org>
[official-gcc.git] / gcc / testsuite / g++.dg / parse / defarg4.C
blob39d0a89904ffd832b73c4643b6f01947347d9c0f
1 // { dg-do compile }
3 // Copyright (C) 2003 Free Software Foundation, Inc.
4 // Contributed by Nathan Sidwell 3 Jul 2003 <nathan@codesourcery.com>
6 // PR c++ 9162. default args got left unprocessed
8 struct S {
9   friend int foo (int = 100);
11 int i = foo ();
13 struct R
15   template <typename T> R (T, int = 0);
18 int Foo ()
20   R s (1);
23 template <typename T> struct Q
25   int Foo (T, int = 0);
28 int Foo (Q<int> *s)
30   s->Foo (1);