New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
deprecated conversion from string constant to char * #51201
Comments
Many Python API functions are causing GCC to rightly complain g++ reports example.cxx:633: warning: deprecated conversion from string The example I encountered today, while testing PyCXX against Would a patch help progress this issue? |
A patch would definitely help. Such a patch shouldn't whole-sale replace |
See also issue bpo-1699259. |
I'd guess that this change can first be made against 2.7 and 3.2 Where do I find the source code to generate the patch against |
Take a look at http://www.python.org/dev, specifically the 'How to Get |
I'm setting the targets to 2.7/3.2 per the discussion in issue bpo-1699259. |
Here is my 1st patch to allow const char * and const Py_UNICODE * What I have attempted to do is stop the public API of python needing Please give feedback and let me know if you wish me raise anything I'm happy to produce a 3.2 version of the patch after the 2.7 version Barry |
Without looking into the details: the places where you cast-away |
I was trying to avoid changing the const ness of output parameters.
Given your feedback I'm guessing you want me to go further with Barry |
Ah, ok - as I said, I didn't look into detail further. IIUC, changing Rather than having the casts, I think I would prefer to take no action |
Updated patch with comment explaining cast. |
Drop 2.7 as it's gone. See also bpo-1699259. |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: