Kay Hayen, 06.09.2010 23:21:
> Am 06.09.2010 23:12, schrieb Stefan Behnel:
>> Kay Hayen, 06.09.2010 23:04:
>>> Am 06.09.2010 22:07, schrieb Stefan Behnel:
>>>> That's not the problem we are discussing here, though. This thread is about
>>>> *C string* literals, which should or should not change due to
>>>> unicode_literals being enabled. That's the question.
>>>>
>>>> I think it makes sense to keep the two discussions separate.
>>>
>>> Wasn't this why wchar_t was invented?
>>
>> Now we're really drifting off-topic. ;)
>>
>> No, that's totally unrelated. The "wchar_t" type is used internally for
>> Unicode strings (typedef-ed to "Py_UNICODE") by CPython on Windows. It has
>> nothing to do with the char* type used to represent C (byte!) strings, and
>> in particular, it has nothing to do with the *content* of C byte strings
>> and its mapping from C byte string literals in Cython code, which is what
>> this discussion is about.
>
> Well, if the discussion is about solving Lisandro's goals, then it is
> about how Python literals can be matched with a C type.
Not at all. Please see the other thread that Lisandro started regarding the
background ("other issues with cython -3"). It only deals with different
Python string types, not with C types.
> That other topic, of C string literals seems like solving a problem that
> shouldn't exist. Why should the Python code use unicode literals and the
> C code not, that is just incompatible to Python.
I don't think I understand what you are trying to say here. We are talking
about the interpretation of string literals *in Cython code* here. C code
doesn't know about Unicode, it only knows about char*, i.e. byte sequences.
It doesn't matter that there are types like "wchar_t" when you actually
need to talk to something that wants a char*. Did you actually read the
entire thread?
Stefan
_______________________________________________
Cython-dev mailing list
[email protected]
http://codespeak.net/mailman/listinfo/cython-dev