~ubuntu-branches/ubuntu/maverick/aspectc++/maverick

« back to all changes in this revision

Viewing changes to AspectC++/tests/PrivateResult/main.cc

  • Committer: Bazaar Package Importer
  • Author(s): Reinhard Tartler
  • Date: 2008-04-10 17:40:52 UTC
  • mfrom: (1.1.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20080410174052-xdnsm7oi8hauyyf1
Tags: 1.0pre4~svn.20080409+dfsg-3
Fix another missing include, this time in Ag++/StdSystem.cc

Show diffs side-by-side

added added

removed removed

Lines of Context:
13
13
  return f ();
14
14
}
15
15
 
 
16
AUnion h () {
 
17
  AUnion u;
 
18
  return u;
 
19
}
 
20
 
16
21
int main () {
17
22
  printf ("PrivateResult: advice for functions returning object with\n");
18
23
  printf ("               non-public default constructor/assignment op.\n");
19
24
  printf ("============================================================\n");
20
25
  Safe s(f ());
21
26
  g ();
 
27
  Safe s2 (1);
 
28
  printf ("------------------------------------------------------------\n");
 
29
  printf ("problem with private inner types:\n");
 
30
  Safe::Inner i = s2.uses_private_inner1 ();
 
31
  const Safe::Inner &r = s2.uses_private_inner2 ();
 
32
  printf ("------------------------------------------------------------\n");
 
33
  printf ("return a union:\n");
 
34
  AUnion u = h ();
22
35
  printf ("============================================================\n");
23
36
}