[Python-Dev] Fun with numbers (original) (raw)

Barry A. Warsaw barry@zope.com
Thu, 25 Apr 2002 18:46:01 -0400


Tim, Jeremy, and I are having so much fun... :) -Barry

-------------------- snip snip -------------------- Python 2.3a0 (#14, Apr 23 2002, 18:26:18) [GCC 2.96 20000731 (Mandrake Linux 8.2 2.96-0.76mdk)] on linux2 Type "help", "copyright", "credits" or "license" for more information.

3 .class <type 'int'> [9903 refs] 3 .class = int [9903 refs] 3 .class = float Traceback (most recent call last): File "", line 1, in ? TypeError: class assignment: 'float' object layout differs from 'int' [9939 refs] 3 .class = bool [9939 refs] 3 True [9939 refs] 3L .class = int Traceback (most recent call last): File "", line 1, in ? TypeError: 'long' object has only read-only attributes (assign to .class) [9939 refs] 23000 .class = bool Debug memory block at address p=0x814f544: 485823496 bytes originally requested the 4 pad bytes at p-4 are not all FORBIDDENBYTE (0xfb): at p-4: 0x7a *** OUCH at p-3: 0x61 *** OUCH at p-2: 0xc8 *** OUCH at p-1: 0x3c *** OUCH the 4 pad bytes at tail=0x250a094c are Segmentation fault