Why not 3.__class__ ?

Tim Peters tim.one at home.com
Tue Oct 9 21:01:43 EDT 2001


In case anyone is still wondering, you will never be able to write

    3.attribute

in Python without getting a richly deserved SyntaxError for your trouble.

    3 .attribute

works fine, as does the ever-popular

    (1+2).attribute

and the less popular

    3\
    .\
    attribute

and the increasingly popular

    (3
        .
     attribute)

We're still debating whether to require that floating zero be spelled

    42j.real

helpfully y'rs  - tim





More information about the Python-list mailing list