summaryrefslogtreecommitdiffstats
path: root/Objects
Commit message (Collapse)AuthorAgeFilesLines
* fileobject.c: fix nasty bug; Makefile; turn on STROP and change lint flags.Guido van Rossum1992-12-221-1/+1
|
* * classobject.c: in instance_lenth, test result of call_objectGuido van Rossum1992-11-261-0/+2
| | | | | | for exception before using it. Fixed a few other places where the outcome of calling sq_length wasn't tested for exceptions (bltinmodule.c, ceval.c).
* * bltinmodule.c: added built-in function cmp(a, b)Guido van Rossum1992-10-181-10/+65
| | | | | | | | | | | | | | | * flmodule.c: added {do,check}_only_forms to fl's list of functions; and don't print a message when an unknown object is returned. * pythonrun.c: catch SIGHUP and SIGTERM to do essential cleanup. * Made jpegmodule.c smaller by using getargs() and mkvalue() consistently. * Increased parser stack size to 500 in parser.h. * Implemented custom allocation of stack frames to frameobject.c and added dynamic stack overflow checks (value stack only) to ceval.c. (There seems to be a bug left: sometimes stack traces don't make sense.)
* Modified most (but not yet all) I/O to always go through sys.stdout orGuido van Rossum1992-09-251-6/+143
| | | | | | sys.stderr or sys.stdin, and to work with any object as long as it has a write() (respectively readline()) methods. Some functions that took a FILE* argument now take an object* argument.
* * Makefile: added IMGFILE; moved some stuff around.Guido van Rossum1992-09-178-114/+9
| | | | | | | | * 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.
* Made builtins int(), long(), float(), oct() and hex() more generic.Guido van Rossum1992-09-124-0/+148
|
* classobject.c moduleobject.c stdwinmodule.c xxobject.c:Guido van Rossum1992-09-043-9/+29
| | | | | raise AttributeError, not KeyError, when attribute deletion fails. sunaudiodevmodule.c: check for deletion before calling setmember.
* Remove outdated warning in comments.Guido van Rossum1992-09-031-3/+0
|
* Remove bogus type-and-refcnt setting from newsizedstringobject().Guido van Rossum1992-09-031-3/+0
|
* Compare instance methods by comparing the object and the function.Guido van Rossum1992-09-031-1/+11
|
* If a type has a repr function but no print function, printing it nowGuido van Rossum1992-09-031-5/+34
| | | | | | | | calls the repr function. When the refcount is bad, don't print the object at all (chances of crashes). Changes to checking and printing of references: the consistency check is somewhat faster; don't print strings referenced once (most occur in function's name lists).
* * renamed malloc.h mymalloc.h, and added MALLARG as the type of theGuido van Rossum1992-08-191-1/+7
| | | | | | | | argument to malloc() (size_t or unsigned int) * listobject.c: check for overflow of the size of the object, so things like range(0x7fffffff) will raise MemoryError instead of calling malloc() with -4 (and then crashing -- malloc's fault)
* oct(0) should return '0', not '00'Guido van Rossum1992-08-141-2/+4
|
* * macmodule.c: include allobjects.h, not .cGuido van Rossum1992-08-141-5/+5
| | | | | | * timemodule.c: the mac has no unistd.h * classobject.c: fixed several cases of return NULL that should be return -1 !!!
* * classobject.[ch], {float,long,int}object.c, bltinmodule.c:Guido van Rossum1992-08-143-56/+91
| | | | | | coercion is now completely generic. * ceval.c: for instances, don't coerce for + and *; * reverses arguments if left one is non-instance numeric and right one sequence.
* * xxobject.c: added tp_as_number, tp_as_sequence, tp_as_mapping toGuido van Rossum1992-08-141-6/+9
| | | | the type object.
* Changes so that user-defined classes can implement operations invokedGuido van Rossum1992-08-121-7/+494
| | | | | by special syntax: you can now define your own numbers, sequences and mappings.
* * Makefile: cosmeticsGuido van Rossum1992-08-052-16/+46
| | | | | | | | | | | | | | | | | | | | | | | | | * socketmodule.c: get rid of makepair(); fix makesocketaddr to fix broken recvfrom() * socketmodule: get rid of getStrarg() * ceval.h: move eval_code() to new file eval.h, so compile.h is no longer needed. * ceval.c: move thread comments to ceval.h; always make save/restore thread functions available (for dynloaded modules) * cdmodule.c, listobject.c: don't include compile.h * flmodule.c: include ceval.h * import.c: include eval.h instead of ceval.h * cgen.py: add forground(); noport(); winopen(""); to initgl(). * bltinmodule.c, socketmodule.c, fileobject.c, posixmodule.c, selectmodule.c: adapt to threads (add BGN/END SAVE macros) * stdwinmodule.c: adapt to threads and use a special stdwin lock. * pythonmain.c: don't include getpythonpath(). * pythonrun.c: use BGN/END SAVE instead of direct calls; also more BGN/END SAVE calls etc. * thread.c: bigger stack size for sun; change exit() to _exit() * threadmodule.c: use BGN/END SAVE macros where possible * timemodule.c: adapt better to threads; use BGN/END SAVE; add longsleep internal function if BSD_TIME; cosmetics
* * Makefile adapted to changes below.Guido van Rossum1992-08-041-2/+9
| | | | | | | | | | | * split pythonmain.c in two: most stuff goes to pythonrun.c, in the library. * new optional built-in threadmodule.c, build upon Sjoerd's thread.{c,h}. * new module from Sjoerd: mmmodule.c (dynamically loaded). * new module from Sjoerd: sv (svgen.py, svmodule.c.proto). * new files thread.{c,h} (from Sjoerd). * new xxmodule.c (example only). * myselect.h: bzero -> memset * select.c: bzero -> memset; removed global variable
* listobject.c: added optional cmp function to list.sort().Guido van Rossum1992-08-031-7/+54
|
* fileobject.c: fix fatal bug in getline() (forgot to initialize fp now)Guido van Rossum1992-07-311-0/+1
|
* Makefile: added instann rules and $(*DEST*) defines.Guido van Rossum1992-07-061-48/+46
| | | | | fileobject.c: report more moeaningful error for I/O on closed files; user getargs() everywhere.
* Changes for new UNIX-specific built-in module 'select' and new header forGuido van Rossum1992-06-231-0/+11
| | | | | interfaces to variants of select() system call, "myselect.h". This includes adding fileno() methods to files, sockets and stdwin.
* sysmodule.c: calling sys.settrace() or sys.setprofile() withoutGuido van Rossum1992-06-191-0/+1
| | | | | | | | | arguments crashed in INCREF() calls which should be XINCREF() calls. timemodule.c: fix for SEQUENT port (sys/select, struct timezone) by Jaap Vermeulen xxobject.c: include modsupport.h
* New copyrightGuido van Rossum1992-04-061-1/+1
|
* Copyright for 1992 addedGuido van Rossum1992-04-0513-13/+13
|
* Don't allow assignment to attributes named __*__Guido van Rossum1992-04-051-2/+16
|
* lint fixGuido van Rossum1992-03-272-3/+11
|
* answer lint's complaintsGuido van Rossum1992-03-271-5/+13
|
* Lint stuff (involves casts, yuck!)Guido van Rossum1992-03-271-27/+33
|
* LintGuido van Rossum1992-03-271-1/+2
| | | | ./
* LintGuido van Rossum1992-03-271-1/+2
|
* Fix lint bugGuido van Rossum1992-03-271-1/+3
|
* Lint...Guido van Rossum1992-03-271-0/+1
|
* Silence lintGuido van Rossum1992-03-271-2/+2
|
* Quiet lintGuido van Rossum1992-03-271-3/+2
|
* Change error handling. Call clearerr() more often.Guido van Rossum1992-03-041-15/+11
|
* Include modsupport.h for getargs().Guido van Rossum1992-01-272-0/+2
|
* Get rid of redundant type checks.Guido van Rossum1992-01-261-53/+26
| | | | Define % operator similar to int%int.
* Add prototypes.Guido van Rossum1992-01-191-105/+148
| | | | Change / and % to match divmod.
* Make / and % do the same as divmod.Guido van Rossum1992-01-191-117/+67
|
* New function gettupleslice(v, i, j).Guido van Rossum1992-01-141-0/+12
|
* Changed to 2's complement bitwise ops. Got rid of ZABS etc.Guido van Rossum1992-01-141-306/+195
|
* Different shift implementation.Guido van Rossum1992-01-141-2/+34
|
* Added READONLY specifier to data members.Guido van Rossum1992-01-141-2/+2
|
* Added f_lasti and f_lineno members.Guido van Rossum1992-01-141-0/+4
|
* Fixed bug in long masking ops.Guido van Rossum1991-12-311-28/+31
|
* Change error messages for impossible assignment slightly.Guido van Rossum1991-12-241-2/+4
|
* Fix assignment of a list to a slice of itself.Guido van Rossum1991-12-241-1/+10
|
* Added message to EOFError.Guido van Rossum1991-12-241-1/+2
|