On 2/10/06, Guido van Rossum <guido at python.org> wrote: > On 2/10/06, Tim Peters <tim.peters at gmail.com> wrote: > > [Jeremy] > > I added some const to several API functions that take char* but > > typically called by passing string literals. > > > > If he had _stuck_ to that, we wouldn't be having this discussion :-) > > (that is, nobody passes string literals to > > PyArg_ParseTupleAndKeywords's kws argument). > > Is it too late to revert this one? The change is still beneficial to C++ programmers, so my initial preference is to keep it. There are still some benefits to the other changes, so it's isn't a complete loss if we revert it. > Is there another way to make C++ programmers happy (e.g. my having a > macro that expands to const when compiled with C++ but vanishes when > compiled with C?) Sounds icky. Are we pretty sure there is no way to do the right thing in plain C? That is, declare the argument as taking a set of const strings and still allow non-const strings to be passed without warning. Jeremy
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4