Commit Graph

8 Commits

Author SHA1 Message Date
Guido van Rossum 50e9fb9e2d Completely get rid of PyClass and PyInstance.
(classobject.[ch] aren't empty yet because they also define PyMethod.)
This breaks lots of stuff, notably cPickle. But it's a step in the right
direction. I'll clean it up later.
(Also a few unrelated changes, e.g. T_NONE to define a "struct member"
that is always None, and simplification of __hash__ -- these are unfinished.)
2006-08-17 05:42:55 +00:00
Guido van Rossum 3cf5b1eef9 Get rid of most of the flags (in tp_flags) that keep track of various
variations of the type struct and its attachments.  In Py3k, all type
structs have to have all fields -- no binary backwards compatibility.
Had to change the complex object to a new-style number!
2006-07-27 21:53:35 +00:00
Guido van Rossum 2018831b2b Adding bytes.join() -- a class methods that concatenates an iterable of bytes.
The name and API are questionable, but the functionality isn't.
2006-05-05 15:15:40 +00:00
Guido van Rossum a0867f79bb Optimizations for bytes reallocation.
This uses up to 12.5% overallocation, not entirely unlike list_resize().
Could probably use more tweaks for odd allocation patterns, TBD.

Also add __alloc__() method which returns the actually allocated size.

PS. I'm now convinced that we need something like "".join(); later.
2006-05-05 04:34:18 +00:00
Guido van Rossum 13e57219d3 Implement bytes += bytes, bytes *= int, int in bytes, bytes in bytes. 2006-04-27 22:54:26 +00:00
Guido van Rossum d624f18a21 Added much functionality to the bytes type.
Change file.readinto() to require binary mode.
2006-04-24 13:47:05 +00:00
Guido van Rossum e06b6b8ff5 Fix a leak and a buglet discovered by Thomas.
Get rid of silly lambdas in the unit test suite.
Add a TODO list to the unit test suite (TDD style).
2006-04-23 07:43:54 +00:00
Guido van Rossum 4dfe8a1131 Here is a bytes type. It's very minimal but it's a start. 2006-04-22 23:28:04 +00:00