[pygccxml-commit] SF.net SVN: pygccxml: [612] pyplusplus_dev/unittests/data
Brought to you by:
mbaas,
roman_yakovenko
From: <rom...@us...> - 2006-10-04 00:43:21
|
Revision: 612 http://svn.sourceforge.net/pygccxml/?rev=612&view=rev Author: roman_yakovenko Date: 2006-10-01 12:49:39 -0700 (Sun, 01 Oct 2006) Log Message: ----------- adding few test cases for recently reported bugs Modified Paths: -------------- pyplusplus_dev/unittests/data/classes_to_be_exported.hpp pyplusplus_dev/unittests/data/split_module_bug_to_be_exported.hpp Modified: pyplusplus_dev/unittests/data/classes_to_be_exported.hpp =================================================================== --- pyplusplus_dev/unittests/data/classes_to_be_exported.hpp 2006-10-01 19:37:00 UTC (rev 611) +++ pyplusplus_dev/unittests/data/classes_to_be_exported.hpp 2006-10-01 19:49:39 UTC (rev 612) @@ -1,94 +1,100 @@ -// Copyright 2004 Roman Yakovenko. -// Distributed under the Boost Software License, Version 1.0. (See -// accompanying file LICENSE_1_0.txt or copy at -// http://www.boost.org/LICENSE_1_0.txt) - -#ifndef __classes_to_be_exported_hpp__ -#define __classes_to_be_exported_hpp__ - -namespace classes{ - -namespace fundamentals{ - -struct fundamental1{}; - -struct fundamental2{}; - -} - -namespace hierarchical{ - -struct fruit{}; - -struct apple : public fruit{}; - -} - -namespace noncopyables{ - -class noncopyable1{ -public: - noncopyable1(){} -private: - noncopyable1( const noncopyable1& ); -}; - -} - -namespace abstracts{ - -class abstract{ -public: - abstract(){} - abstract(int){} - abstract(int, double, const abstract&){} -public: - - virtual int pure_virtual(const abstract& ) const = 0; - - virtual bool overloaded_virtual(){ return true;} - virtual bool overloaded_virtual(int){ return true;} - - virtual int overloaded_pure_virtual(int) const = 0; - virtual void overloaded_pure_virtual(double) const = 0; - - virtual int some_virtual(){ return 1; } -}; - -} - -namespace constructors{ - -struct constructor1{ - constructor1(){} - constructor1( const constructor1& ){} - constructor1(int x, int y){} - constructor1(int y, const constructor1& x ){} - - constructor1( const double ){} - struct internal_data{}; - constructor1( const internal_data ){} -}; - -} - -namespace scope_based{ -struct scope_based_exposer{ - enum EColor{ red, green, blue }; - scope_based_exposer(){} -}; -} - -namespace protected_static{ -class protected_static_t{ -protected: - static int identity(int x){ return x; } - - int invert_sign(int x){ return -1*x; } -}; -}; - -}//classes - -#endif//__classes_to_be_exported_hpp__ - +// Copyright 2004 Roman Yakovenko. +// Distributed under the Boost Software License, Version 1.0. (See +// accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +#ifndef __classes_to_be_exported_hpp__ +#define __classes_to_be_exported_hpp__ + +namespace classes{ + +namespace fundamentals{ + +struct fundamental1{}; + +struct fundamental2{}; + +} + +namespace hierarchical{ + +struct fruit{}; + +struct apple : public fruit{}; + +} + +namespace noncopyables{ + +class noncopyable1{ +public: + noncopyable1(){} +private: + noncopyable1( const noncopyable1& ); +}; + +} + +namespace abstracts{ + +class abstract{ +public: + abstract(){} + abstract(int){} + abstract(int, double, const abstract&){} +public: + + virtual int pure_virtual(const abstract& ) const = 0; + + virtual bool overloaded_virtual(){ return true;} + virtual bool overloaded_virtual(int){ return true;} + + virtual int overloaded_pure_virtual(int) const = 0; + virtual void overloaded_pure_virtual(double) const = 0; + + virtual int some_virtual(){ return 1; } +}; + +} + +namespace constructors{ + +struct constructor1{ + constructor1(){} + constructor1( const constructor1& ){} + constructor1(int x, int y){} + constructor1(int y, const constructor1& x ){} + + constructor1( const double ){} + struct internal_data{}; + constructor1( const internal_data ){} +}; + +} + +namespace scope_based{ +struct scope_based_exposer{ + enum EColor{ red, green, blue }; + scope_based_exposer(EColor c=blue){} +}; +} + +namespace protected_static{ +class protected_static_t{ +protected: + static int identity(int x){ return x; } + + int invert_sign(int x){ return -1*x; } +}; +}; + +namespace non_public_hierarchy{ + +struct protected_base{}; +struct protected_derived : protected protected_base{}; + +} + +}//classes + +#endif//__classes_to_be_exported_hpp__ Modified: pyplusplus_dev/unittests/data/split_module_bug_to_be_exported.hpp =================================================================== --- pyplusplus_dev/unittests/data/split_module_bug_to_be_exported.hpp 2006-10-01 19:37:00 UTC (rev 611) +++ pyplusplus_dev/unittests/data/split_module_bug_to_be_exported.hpp 2006-10-01 19:49:39 UTC (rev 612) @@ -6,10 +6,14 @@ #ifndef __split_module_bug_to_be_exported_hpp__ #define __split_module_bug_to_be_exported_hpp__ +#include <vector> + typedef struct opaque_ *opaque_pointer; inline opaque_pointer get_opaque(){ return 0; } inline opaque_pointer get_opaque2(){ return 0; } +typedef std::vector<int> int_vector; +inline int_vector get_vector(){ return int_vector(); } #endif//__split_module_to_be_exported_hpp__ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |