summaryrefslogtreecommitdiffstats
path: root/Objects/methodobject.c
Commit message (Collapse)AuthorAgeFilesLines
* REMOVED all CWI, CNRI and BeOpen copyright markings.Guido van Rossum2000-09-011-9/+0
| | | | This should match the situation in the 1.6b1 tree.
* ANSI-fication of the sources.Fred Drake2000-07-091-31/+13
|
* Change copyright notice - 2nd try.Guido van Rossum2000-06-301-6/+0
|
* Change copyright notice.Guido van Rossum2000-06-301-21/+6
|
* Fix an error on AIX by using a proper cast.Guido van Rossum2000-06-301-1/+1
|
* Trent Mick <trentm@activestate.com>:Fred Drake2000-06-301-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | The common technique for printing out a pointer has been to cast to a long and use the "%lx" printf modifier. This is incorrect on Win64 where casting to a long truncates the pointer. The "%p" formatter should be used instead. The problem as stated by Tim: > Unfortunately, the C committee refused to define what %p conversion "looks > like" -- they explicitly allowed it to be implementation-defined. Older > versions of Microsoft C even stuck a colon in the middle of the address (in > the days of segment+offset addressing)! The result is that the hex value of a pointer will maybe/maybe not have a 0x prepended to it. Notes on the patch: There are two main classes of changes: - in the various repr() functions that print out pointers - debugging printf's in the various thread_*.h files (these are why the patch is large) Closes SourceForge patch #100505.
* This patch addresses two main issues: (1) There exist some non-fatalFred Drake2000-06-291-2/+8
| | | | | | | | | | | | | | | | | | | | errors in some of the hash algorithms. For exmaple, in float_hash and complex_hash a certain part of the value is not included in the hash calculation. See Tim's, Guido's, and my discussion of this on python-dev in May under the title "fix float_hash and complex_hash for 64-bit *nix" (2) The hash algorithms that use pointers (e.g. func_hash, code_hash) are universally not correct on Win64 (they assume that sizeof(long) == sizeof(void*)) As well, this patch significantly cleans up the hash code. It adds the two function _Py_HashDouble and _PyHash_VoidPtr that the various hashing routine are changed to use. These help maintain the hash function invariant: (a==b) => (hash(a)==hash(b))) I have added Lib/test/test_hash.py and Lib/test/output/test_hash to test this for some cases.
* Vladimir Marangozov's long-awaited malloc restructuring.Guido van Rossum2000-05-031-3/+2
| | | | | | | | | | For more comments, read the patches@python.org archives. For documentation read the comments in mymalloc.h and objimpl.h. (This is not exactly what Vladimir posted to the patches list; I've made a few changes, and Vladimir sent me a fix in private email for a problem that only occurs in debug mode. I'm also holding back on his change to main.c, which seems unnecessary to me.)
* The rest of the changes by Trent Mick and Dale Nagata for warning-freeGuido van Rossum2000-01-201-1/+1
| | | | compilation on NT Alpha. Mostly added casts etc.
* When comparing bound methods, use identity test on the objects,Guido van Rossum1998-12-041-1/+1
| | | | not equality test.
* Marc-Andre Lemburg's patch to move the typedef for PyCFunctionObjectGuido van Rossum1998-07-101-6/+0
| | | | to the .h file and add macros there for inlined access to the fields.
* New feature: if the object's type has a non-NULL tp_doc field, thatGuido van Rossum1998-06-271-2/+9
| | | | | | is returned as the object's __doc__ attribute. (If only the list of methods would be referenced from the type...)
* Added separate free list for cfunction (builtin method) objects, for aGuido van Rossum1997-08-051-7/+30
| | | | few percent speed up. Also add PyCFunction_Fini() to discard it.
* Quickly renamed the last directory.Guido van Rossum1997-05-021-77/+79
|
* New permission notice, includes CNRI.Guido van Rossum1996-10-251-12/+19
|
* changes for keyword args to built-in functions and classesGuido van Rossum1995-07-261-2/+2
|
* added findmethodinchain and methodchain data typesGuido van Rossum1995-01-261-23/+50
|
* add restrictions in restricted modeGuido van Rossum1995-01-101-1/+7
|
* * Objects/methodobject.c: changed drastically, the object nowGuido van Rossum1995-01-071-27/+44
| | | | | contains a pointer to the struct methodlist (which must be static); added attributes __name__, __doc__ and __self__
* Added 1995 to copyright message.Guido van Rossum1995-01-041-10/+13
| | | | | floatobject.c: fix hash(). methodobject.c: support METH_FREENAME flag bit.
* Lots of minor changes. Note for mappingobject.c: the hash table pointerGuido van Rossum1995-01-021-1/+1
| | | | can now be NULL.
* Merge back to main trunkGuido van Rossum1994-08-301-5/+5
|
* * ceval.c, longobject.c, methodobject.c, listnode.c, arraymodule.c,Guido van Rossum1993-11-011-1/+1
| | | | | | pythonrun.c: added static forward declarations * pythonrun.h, ceval.h, longobject.h, node.h: removed declarations of static routines
* * Lots of small changes related to access.Guido van Rossum1993-05-211-2/+2
| | | | | | | * Added "access *: ...", made access work for class methods. * Introduced subclass check: make sure that when calling ClassName.methodname(instance, ...), the instance is an instance of ClassName or of a subclass thereof (this might break some old code!)
* * Changed all copyright messages to include 1993.Guido van Rossum1993-03-291-5/+36
| | | | | | | | | | | | | | | | | * Stubs for faster implementation of local variables (not yet finished) * Added function name to code object. Print it for code and function objects. THIS MAKES THE .PYC FILE FORMAT INCOMPATIBLE (the version number has changed accordingly) * Print address of self for built-in methods * New internal functions getattro and setattro (getattr/setattr with string object arg) * Replaced "dictobject" with more powerful "mappingobject" * New per-type functio tp_hash to implement arbitrary object hashing, and hashobject() to interface to it * Added built-in functions hash(v) and hasattr(v, 'name') * classobject: made some functions static that accidentally weren't; added __hash__ special instance method to implement hash() * Added proper comparison for built-in methods and functions
* * Makefile: added IMGFILE; moved some stuff around.Guido van Rossum1992-09-171-17/+2
| | | | | | | | * flmodule.c: added some missing functions; changed readonly flags of some data members based upon FORMS documentation. * listobject.c: fixed int/long arg lint bug (bites PC compilers). * several: removed redundant print methods (repr is good enough). * posixmodule.c: added (still experimental) process group functions.
* Copyright for 1992 addedGuido van Rossum1992-04-051-1/+1
|
* LintGuido van Rossum1992-03-271-1/+2
| | | | ./
* Add "varargs" attribute.Guido van Rossum1991-12-161-5/+20
|
* Use AttributeError.Guido van Rossum1991-12-101-1/+1
|
* Implemented __methods__ attributeGuido van Rossum1991-10-201-0/+27
|
* printobject now returns an error codeGuido van Rossum1991-06-071-1/+2
|
* Added copyright notice.Guido van Rossum1991-02-191-0/+24
|
* "Compiling" versionGuido van Rossum1990-12-201-16/+25
|
* New errors.Guido van Rossum1990-10-211-2/+3
|
* Initial revisionGuido van Rossum1990-10-141-0/+113