[C++-sig] py++ and indexing_v2

2009-05-19 Thread james
published code rather than commit the project to our own version of boost or add another step to the code generation. Is there a way of telling py++ to use the different namespace and directory? Or am I misunderstanding some things? Thanks for any help James. -- Ring the bells that still can

[C++-sig] Documentation bug

2009-08-05 Thread Daniel James
Hi, Trac ticket 1890, 'Missing parameters in example code' looks like a pretty trivial fix, if someone can confirm that it's correct, I'll make the change if no one else can. https://svn.boost.org/trac/boost/ticket/1890 > On the page: > > http://www.boost.org/doc/libs/1_35_0/libs/python/doc/tuto

[C++-sig] boost python to/from python type conversion

2009-09-30 Thread James Amundson
Hi, I'm trying to write to/from type converters for my code, and I'm stuck. My case doesn't map well to any of those in the boost python documentation. I'm trying to pass objects of type MPI_Comm (really a C type!) back and forth with mpi4py (which uses cython internally.) The mpi4py author h

Re: [C++-sig] boost python to/from python type conversion

2009-10-01 Thread James Amundson
On 09/30/2009 11:48 PM, Ralf W. Grosse-Kunstleve wrote: lvalue_from_pytype only works for passing by value or const references/pointers, but that seems to match your case, since you MPI_Comm is passed by value to your sayhello(). However, wrapping extern "C" isn't portable, AFAIK. You'll need a

Re: [C++-sig] boost python to/from python type conversion

2009-10-01 Thread James Amundson
On 10/01/2009 01:22 AM, Austin Bingham wrote: If it's any help, I wrote a small bit on the details of writing converters. It might help clarify some of the mechanics which, I agree, are a bit mysterious: http://misspent.wordpress.com/2009/09/27/how-to-write-boost-python-converters/ Wond

[C++-sig] How do I wrap a static member function?

2009-10-30 Thread James Amundson
Hi, I have the following code: --- #include #include class Foo { public: Foo() {} ; static void doit(const char * message) { std::cout << "doing it statically: " << message << "\n"; }; void non

Re: [C++-sig] How do I wrap a static member function?

2009-11-04 Thread James Amundson
On 10/30/2009 10:43 PM, Ravi wrote: Use class_.staticmethod(...) as shown below: Thanks. That's what I needed. Best, Jim Amundson ___ Cplusplus-sig mailing list Cplusplus-sig@python.org http://mail.python.org/mailman/listinfo/cplusplus-sig

[C++-sig] Exceptions with pybindgen and gccxmlparser

2010-02-11 Thread James Vogel
ething afoot in the gccxml parsing that isn't picking up the throw clause in the virtual class; I'm just not sure if there's an annotation I might be missing, or some other issue. Anyone seen this before? James. ___ Cplusplus-sig maili

[C++-sig] Boost python exception translation failure on BlueGene/P

2010-02-18 Thread James Amundson
Boost Python seems to be failing to catch and translate C++ exceptions for me on a BlueGene/P installation. I really don't know what to do next in debugging the problem, so I would appreciate any advice. I have a simple test module, pyexcept -

Re: [C++-sig] Boost python exception translation failure on BlueGene/P

2010-02-18 Thread James Amundson
On 02/18/2010 05:19 PM, Ralf W. Grosse-Kunstleve wrote: Your problem may be that an exception thrown in one .so isn't correctly caught in another .so. Hmmm. I only have one module in my test -- pyexcept. Is the fact that it has to link to libboost_python enough to cause that problem? In th

Re: [C++-sig] Boost python exception translation failure on BlueGene/P

2010-02-24 Thread James Amundson
On 02/18/2010 04:24 PM, James Amundson wrote: Boost Python seems to be failing to catch and translate C++ exceptions for me on a BlueGene/P installation. I really don't know what to do next in debugging the problem, so I would appreciate any advice. I have finally solved this problem m

Re: [C++-sig] Generating API documentation when using boost::python

2010-04-15 Thread James Amundson
On 04/15/2010 03:53 AM, Murray Cumming wrote: (If anyone can suggest a better alternative to nasty pydoc, I'd be glad.) Well, Sphinx, , is the new standard for Python documentation, but I don't think it has any way to extract documentation from your boost python

[C++-sig] Boost.Python Metaclass

2011-02-15 Thread James Emerton
place of == &class_metatype_object should be sufficient to allow me to derive metaclasses from Boost.Python.class. Does anyone have any advice, comments or objections before I proceed? James ___ Cplusplus-sig mailing list Cplusplus-sig@pyt

[C++-sig] group meeting today

2011-04-21 Thread James Amundson
Today we will have another technical group meeting. Alex and I will discuss approaches to canonical transformations and Lorentz boosts in space charge calculations. --Jim ___ Cplusplus-sig mailing list Cplusplus-sig@python.org http://mail.python.org/

Re: [C++-sig] group meeting today

2011-04-21 Thread James Amundson
I apologize for my clumsy fingers. This message was meant for a different mailing list. On 04/21/2011 11:04 AM, James Amundson wrote: Today we will have another technical group meeting. Alex and I will discuss approaches to canonical transformations and Lorentz boosts in space charge

[C++-sig] How can I pass derived Python instances to C++?

2011-09-08 Thread James Amundson
I would like to be able to create a Python class derived from a C++ class, then pass a instance of the Python class back to C++. It isn't clear to me if there is an easy way to do this. Here is a simple example of what I wish worked, but doesn't: C++ side: #include #include class Foo { publ

Re: [C++-sig] How can I pass derived Python instances to C++?

2011-09-08 Thread James Amundson
On 09/08/2011 12:17 PM, Stefan Seefeld wrote: On 2011-09-08 13:01, James Amundson wrote: I would like to be able to create a Python class derived from a C++ class, then pass a instance of the Python class back to C++. It isn't clear to me if there is an easy way to do this. import foo

[C++-sig] Combining Boost Serialization with Boost Python

2012-03-14 Thread James Amundson
I have a use case involving Boost Serialization and Boost Python. I have a (mostly) C++ library wrapped with Python. The C++ code uses Boost Serialization to periodically create checkpoints from which the user can resume later. Getting the serialization and python libraries to work together did

[C++-sig] Exposing std::vector using vector_indexing_suite

2014-11-26 Thread James Bird
result of '0.0'. The 'append' is making a copy such that 'l' and 'd.layers[0]' are two separate objects. We've noticed that one way to make this work is by using shared_ptr in our C++ data structure, but we feel we would have to compromise on our C

[C++-sig] Member overloads signature not matching C++ signature

2015-07-31 Thread James Maddison
l class_ calls from this message. When I make a call to the methods in python I recieve the following error: Traceback (most recent call last): File "/home/james/projects/imgen/patterns/triangles.py", line 46, in draw path.stroke(context) Boost.Python.ArgumentError: P