From: <rom...@us...> - 2008-08-12 04:30:43
|
Revision: 1391 http://pygccxml.svn.sourceforge.net/pygccxml/?rev=1391&view=rev Author: roman_yakovenko Date: 2008-08-12 04:30:53 +0000 (Tue, 12 Aug 2008) Log Message: ----------- adding new use-case Modified Paths: -------------- pyplusplus_dev/unittests/data/indexing_suites_to_be_exported.hpp Modified: pyplusplus_dev/unittests/data/indexing_suites_to_be_exported.hpp =================================================================== --- pyplusplus_dev/unittests/data/indexing_suites_to_be_exported.hpp 2008-08-09 11:25:14 UTC (rev 1390) +++ pyplusplus_dev/unittests/data/indexing_suites_to_be_exported.hpp 2008-08-12 04:30:53 UTC (rev 1391) @@ -1,20 +1,20 @@ -// 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 __indexing_suites_to_be_exported_hpp__ -#define __indexing_suites_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 __indexing_suites_to_be_exported_hpp__ +#define __indexing_suites_to_be_exported_hpp__ + #include <vector> -#include <string> - -namespace indexing_suites { - -typedef std::vector< std::string > strings_t; - -inline void do_nothing( const strings_t& ){} +#include <string> +namespace indexing_suites { + +typedef std::vector< std::string > strings_t; + +inline void do_nothing( const strings_t& ){} + struct item_t{ item_t() : value( -1 ){} @@ -27,23 +27,29 @@ } int value; -}; +}; - -typedef std::vector<item_t> items_t; +typedef std::vector<item_t> items_t; + +typedef std::vector<item_t*> items_ptr_t; + inline item_t get_value( const std::vector<item_t>& vec, unsigned int index ){ return vec.at(index); } +inline item_t get_ptr_value( const std::vector<item_t*>& vec, unsigned int index ){ + return *vec.at(index); +} + inline void set_value( std::vector<item_t>& vec, unsigned int index, item_t value ){ vec.at(index); vec[index] = value; } - -typedef std::vector<int> ivector; -ivector empty_ivector(){ return ivector(); } - -} - -#endif//__indexing_suites_to_be_exported_hpp__ + +typedef std::vector<int> ivector; +ivector empty_ivector(){ return ivector(); } + +} + +#endif//__indexing_suites_to_be_exported_hpp__ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |