Thomas Heller
2fb5ac745b
Fix the ctypes tests. Patch from Victor Stinner. He writes:
...
The problem is that ctypes c_char (and c_char_p) creates unicode string
instead of byte string. I attached a proposition (patch) to change this
behaviour (use bytes for c_char).
So in next example, it will display 'bytes' and not 'str':
from ctypes import c_buffer, c_char
buf = c_buffer("abcdef")
print (type(buf[0]))
Other behaviour changes:
- repr(c_char) adds a "b"
eg. repr(c_char('x')) is "c_char(b'x')" instead of "c_char('x')"
- bytes is mutable whereas str is not:
this may break some modules based on ctypes
2007-08-08 18:47:32 +00:00
..
2007-08-05 15:39:16 +00:00
2007-08-08 18:47:32 +00:00
2007-08-06 23:33:07 +00:00
2007-07-21 00:21:26 +00:00
2007-07-16 23:10:57 +00:00
2007-04-21 15:47:16 +00:00
2007-08-05 15:29:28 +00:00
2007-07-18 18:15:48 +00:00
2007-07-20 00:22:32 +00:00
2007-07-16 23:10:57 +00:00
2007-06-13 18:07:49 +00:00
2007-08-07 14:26:40 +00:00
2007-05-07 22:24:25 +00:00
2007-08-05 15:29:28 +00:00
2007-06-13 18:07:49 +00:00
2007-06-13 18:07:49 +00:00
2007-08-08 17:01:45 +00:00
2007-08-08 17:01:45 +00:00
2007-08-07 23:03:33 +00:00
2007-06-18 17:58:50 +00:00
2007-06-13 18:07:49 +00:00
2007-08-01 17:52:23 +00:00
2007-05-15 18:46:22 +00:00
2007-06-13 18:07:49 +00:00
2007-08-06 23:33:07 +00:00
2007-07-18 20:57:44 +00:00
2007-05-22 21:56:47 +00:00
2007-08-03 20:32:27 +00:00
2007-05-15 18:46:22 +00:00
2007-05-27 09:20:49 +00:00
2007-04-27 19:54:29 +00:00
2007-05-07 22:24:25 +00:00
2007-07-03 08:25:58 +00:00
2007-06-13 18:07:49 +00:00
2007-06-07 23:15:56 +00:00
2007-04-12 22:55:07 +00:00
2007-06-07 22:37:45 +00:00
2007-08-05 15:29:28 +00:00
2007-05-04 13:05:09 +00:00
2007-07-20 00:22:32 +00:00
2007-05-11 16:50:42 +00:00
2007-07-15 13:01:48 +00:00
2007-05-14 22:51:27 +00:00
2007-04-21 15:47:16 +00:00
2007-07-20 00:30:38 +00:00
2007-08-03 19:19:24 +00:00
2007-07-20 00:22:32 +00:00
2007-06-07 23:15:56 +00:00
2007-07-16 23:36:05 +00:00
2007-07-03 08:25:58 +00:00
2007-06-13 18:07:49 +00:00
2007-07-03 08:25:58 +00:00
2007-07-03 08:25:58 +00:00
2007-06-07 23:15:56 +00:00
2007-08-03 18:40:49 +00:00
2007-04-27 19:54:29 +00:00
2007-08-07 05:37:39 +00:00
2007-07-03 08:25:58 +00:00
2007-05-22 18:11:13 +00:00
2007-05-15 18:46:22 +00:00
2007-07-17 20:45:57 +00:00
2007-05-14 22:51:27 +00:00
2007-07-16 23:10:57 +00:00
2007-07-12 08:04:06 +00:00
2007-05-02 19:09:54 +00:00
2007-06-06 16:43:59 +00:00
2007-07-03 08:25:58 +00:00
2007-07-10 13:35:52 +00:00
2007-05-03 17:18:26 +00:00
2007-08-08 17:36:33 +00:00
2007-06-06 23:52:48 +00:00
2007-04-27 19:54:29 +00:00
2007-06-13 18:07:49 +00:00
2007-07-18 18:15:48 +00:00
2007-08-03 20:40:09 +00:00
2007-06-30 05:01:58 +00:00
2007-07-10 11:34:31 +00:00
2007-05-14 22:51:27 +00:00
2007-04-27 19:54:29 +00:00
2007-07-21 00:21:26 +00:00
2007-07-03 08:25:58 +00:00
2007-05-14 22:51:27 +00:00
2007-06-12 00:25:08 +00:00
2007-06-07 23:15:56 +00:00
2007-04-27 19:54:29 +00:00
2007-04-15 12:05:43 +00:00
2007-07-03 08:25:58 +00:00
2007-06-13 21:52:41 +00:00
2007-04-27 19:54:29 +00:00
2007-05-27 09:19:52 +00:00
2007-07-20 00:22:32 +00:00
2007-07-20 00:22:32 +00:00
2007-06-13 18:07:49 +00:00
2007-07-23 00:24:10 +00:00
2007-04-27 19:54:29 +00:00
2007-05-15 18:46:22 +00:00
2007-04-21 15:47:16 +00:00
2007-06-13 18:07:49 +00:00
2007-07-15 14:02:52 +00:00
2007-04-21 15:47:16 +00:00
2007-07-17 00:27:30 +00:00
2007-07-28 17:52:25 +00:00
2007-06-13 18:07:49 +00:00
2007-05-22 18:11:13 +00:00
2007-06-13 18:07:49 +00:00
2007-04-27 19:54:29 +00:00
2007-08-06 23:33:07 +00:00
2007-04-27 19:54:29 +00:00
2007-07-26 03:07:02 +00:00
2007-06-06 23:52:48 +00:00
2007-05-18 00:51:22 +00:00
2007-05-22 18:11:13 +00:00
2007-05-24 17:58:06 +00:00
2007-08-06 23:33:07 +00:00
2007-08-06 23:33:07 +00:00
2007-08-03 20:40:09 +00:00
2007-08-03 19:03:39 +00:00
2007-07-11 13:09:30 +00:00
2007-06-07 23:15:56 +00:00
2007-04-27 19:54:29 +00:00
2007-06-13 18:07:49 +00:00
2007-07-03 08:25:58 +00:00
2007-04-21 15:47:16 +00:00
2007-05-07 22:24:25 +00:00
2007-05-27 09:19:04 +00:00
2007-06-07 21:56:45 +00:00
2007-05-15 18:46:22 +00:00
2007-05-22 18:11:13 +00:00
2007-08-07 18:36:16 +00:00
2007-04-27 19:54:29 +00:00
2007-08-05 22:23:10 +00:00
2007-07-03 08:25:58 +00:00
2007-08-06 23:33:07 +00:00
2007-05-22 18:11:13 +00:00
2007-06-13 18:07:49 +00:00
2007-07-20 00:22:32 +00:00
2007-08-05 15:29:28 +00:00
2007-06-07 23:15:56 +00:00
2007-07-10 09:10:40 +00:00
2007-08-08 17:36:33 +00:00
2007-08-04 19:22:00 +00:00
2007-05-18 00:51:22 +00:00
2007-04-21 15:47:16 +00:00
2007-07-16 19:50:03 +00:00
2007-07-20 17:45:09 +00:00
2007-06-07 23:15:56 +00:00
2007-07-23 21:28:30 +00:00
2007-06-13 18:07:49 +00:00
2007-07-11 13:09:30 +00:00
2007-05-23 20:51:02 +00:00
2007-07-26 03:19:46 +00:00
2007-07-30 03:50:35 +00:00
2007-07-18 22:07:29 +00:00