Skip to content

Commit

Permalink
Merge pull request #5 from pfernique/master
Browse files Browse the repository at this point in the history
Add std::string wrapper
  • Loading branch information
pfernique committed Feb 16, 2017
2 parents 3f8f4ae + 9c45768 commit 961bb66
Show file tree
Hide file tree
Showing 6 changed files with 209 additions and 5 deletions.
2 changes: 1 addition & 1 deletion AutoWIG.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ def stl_refactoring(asg):
asg = stl_refactoring(asg)

autowig.generator.plugin = 'boost_python'
nodes = [typedef.qualified_type.unqualified_type for typedef in asg['::statiskit::stl'].typedefs()]
nodes = [typedef.qualified_type.unqualified_type for typedef in asg['::statiskit::stl'].typedefs()] + asg['class ::std::basic_string'].specializations()
nodes = list(itertools.chain(*[node.bases(inherited=True) for node in nodes])) + nodes + asg['::statiskit::stl'].declarations()
wrappers = autowig.generator(asg, nodes, module='src/py/_stl.cpp',
decorator='src/py/statiskit/stl/_stl.py',
Expand Down
2 changes: 0 additions & 2 deletions SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,6 @@ HEADER = """\
namespace statiskit
{
typedef std::size_t Index;
namespace stl
{
Expand Down
2 changes: 0 additions & 2 deletions src/cpp/STL.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,6 @@

namespace statiskit
{
typedef std::size_t Index;

namespace stl
{

Expand Down
2 changes: 2 additions & 0 deletions src/py/_stl.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include "_stl.h"

void wrapper_10b14312eeb655268489cd34090870cf();
void wrapper_448c20257e485acda59dc59305fceb58();
void wrapper_476c1c1f206251dba7af53c48f3f6e42();
void wrapper_6436891c9b6854f494789a812891cbe5();
void wrapper_745e4933f5b250d9bc5232fe864d0cf7();
Expand All @@ -19,6 +20,7 @@ boost::python::docstring_options docstring_options(1, 0, 0);
BOOST_PYTHON_MODULE(__stl)
{
wrapper_10b14312eeb655268489cd34090870cf();
wrapper_448c20257e485acda59dc59305fceb58();
wrapper_476c1c1f206251dba7af53c48f3f6e42();
wrapper_6436891c9b6854f494789a812891cbe5();
wrapper_745e4933f5b250d9bc5232fe864d0cf7();
Expand Down
4 changes: 4 additions & 0 deletions src/py/statiskit/stl/_stl.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,13 @@

# Group template specializations
__stl.statiskit.stl._Generator = [__stl.statiskit.stl._Generator_10b14312eeb655268489cd34090870cf, __stl.statiskit.stl._Generator_745e4933f5b250d9bc5232fe864d0cf7, __stl.statiskit.stl._Generator_74bc331707c1505eb2f807cae7c32bbb, __stl.statiskit.stl._Generator_e76a1308464d5a9a837d9a61f942fae7]
__stl.std._BasicString = [__stl.std._BasicString_448c20257e485acda59dc59305fceb58]
__stl.std._Vector = [__stl.std._Vector_107131f9768c56e794a9b0de728d1738, __stl.std._Vector_6b9ae5eac40858c9a0f5e6e21c15d1d3, __stl.std._Vector_c047f2c3135554ceb57f166fd404cfc8, __stl.std._Vector_dc5522842bc75d8b9ac7b46020c60854]
__stl.std._Set = [__stl.std._Set_476c1c1f206251dba7af53c48f3f6e42, __stl.std._Set_6436891c9b6854f494789a812891cbe5, __stl.std._Set_858bbf0613575e2ebe4b0e5902107ad6, __stl.std._Set_882a8dd1e64a51b4a9da29ab852a852e]

# Define aliases
__stl.std._Set_6436891c9b6854f494789a812891cbe5.KeyType = __stl.std._BasicString_448c20257e485acda59dc59305fceb58
__stl.std._Set_6436891c9b6854f494789a812891cbe5.ValueType = __stl.std._BasicString_448c20257e485acda59dc59305fceb58
__stl.statiskit.stl.VectorInt = __stl.std._Vector_6b9ae5eac40858c9a0f5e6e21c15d1d3
__stl.statiskit.stl.VectorDouble = __stl.std._Vector_107131f9768c56e794a9b0de728d1738
__stl.statiskit.stl.SetLessDoubleGenerator = __stl.statiskit.stl._Generator_74bc331707c1505eb2f807cae7c32bbb
Expand All @@ -23,3 +26,4 @@
__stl.statiskit.stl.SetLessSizeTGenerator = __stl.statiskit.stl._Generator_10b14312eeb655268489cd34090870cf
__stl.statiskit.stl.SetLessIntGenerator = __stl.statiskit.stl._Generator_e76a1308464d5a9a837d9a61f942fae7
__stl.statiskit.stl.SetLessStringGenerator = __stl.statiskit.stl._Generator_745e4933f5b250d9bc5232fe864d0cf7
__stl.std._Vector_c047f2c3135554ceb57f166fd404cfc8.ValueType = __stl.std._BasicString_448c20257e485acda59dc59305fceb58

0 comments on commit 961bb66

Please sign in to comment.