[Python-Dev] C struct for Str( )

2016-01-15 Thread Eddy Quicksall
I want to fill an Str() string from a C function. But I think I am using the wrong structure (PyBytesObject). I have written a C function to dump the Python class but as you can see the structure I'm using does not match the data in the class. Can someone please tell me the correct structure:

Re: [Python-Dev] C struct for Str( )

2016-01-15 Thread Brett Cannon
I don't quite see what this has to do with has to do with the development of Python, Eddy. You can always reference the C API at https://docs.python.org/3/c-api/index.html . And `PyBytesObject` is an instance of `bytes` in Python. On Fri, 15 Jan 2016 at 15:33 Eddy Quicksall

Re: [Python-Dev] C struct for Str( )

2016-01-15 Thread Eddy Quicksall
Sorry, I must be on the wrong list. Can you please give me the correct list? Eddy From: Brett Cannon [mailto:br...@python.org] Sent: Friday, January 15, 2016 6:58 PM To: Eddy Quicksall; python-dev@python.org Subject: Re: [Python-Dev] C struct for Str( ) I don't quite see what this has

Re: [Python-Dev] C struct for Str( )

2016-01-15 Thread Victor Pantoja
> *From:* Brett Cannon [mailto:br...@python.org] > *Sent:* Friday, January 15, 2016 6:58 PM > *To:* Eddy Quicksall; python-dev@python.org > *Subject:* Re: [Python-Dev] C struct for Str( ) > > > > I don't quite see what this has to do with has to do with the development > of