Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: downloads/boost_1_34_1/libs/python/pyste/tests/inherit.h @ 45

Last change on this file since 45 was 29, checked in by landauf, 17 years ago

updated boost from 1_33_1 to 1_34_1

File size: 658 bytes
Line 
1/* Copyright Bruno da Silva de Oliveira 2003. Use, modification and
2 distribution is subject to the Boost Software License, Version 1.0.
3 (See accompanying file LICENSE_1_0.txt or copy at
4 http:#www.boost.org/LICENSE_1_0.txt)
5 */ 
6namespace inherit {
7   
8template<typename T>
9class A
10{
11public:
12   void set(T v) { mData = v; }
13
14   T get() const { return mData; }
15
16private:
17   T mData;
18};
19
20
21class B : public A<int>
22{
23public:
24   int go() { return get(); }
25};
26
27struct C : B
28{
29    enum ab { a = 1, b = 2 };
30    int f1() { return 1; }
31    int x;
32    static int s;
33};
34
35struct D : C
36{
37    int f2() { return 2; }
38    int y;
39};
40
41struct X {};
42struct E: X, D {};
43}
Note: See TracBrowser for help on using the repository browser.