Re: help() on stdout.closed

2006-06-21 Thread Nick Craig-Wood
Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> wrote: > In <[EMAIL PROTECTED]>, Pekka Karjalainen wrote: > > > Suppose I had no idea what sys.stdout.closed was and wanted to find out. > > Where would I look it up? > > `sys.stdout` is a file (like) object: > > http://docs.python.org/lib/bltin-f

Re: help() on stdout.closed

2006-06-21 Thread Marc 'BlackJack' Rintsch
In <[EMAIL PROTECTED]>, Pekka Karjalainen wrote: > Suppose I had no idea what sys.stdout.closed was and wanted to find out. > Where would I look it up? `sys.stdout` is a file (like) object: http://docs.python.org/lib/bltin-file-objects.html Ciao, Marc 'BlackJack' Rintsch -- http://mai

Re: help() on stdout.closed

2006-06-21 Thread Fredrik Lundh
Pekka Karjalainen wrote: > Suppose I had no idea what sys.stdout.closed was and wanted to find out. > Where would I look it up? >>> help(sys.stdout) ... | closed = | True if the file is closed ... in case anyone feels like hacking, support for something like >>> help(sys.stdout, "close

Re: help() on stdout.closed

2006-06-21 Thread Pekka Karjalainen
On 2006-06-21, Fredrik Lundh <[EMAIL PROTECTED]> wrote: > have you tried things like [...] I have now. I'm not sure what the results are supposed to tell me, but I am not going to press the issue. Suppose I had no idea what sys.stdout.closed was and wanted to find out. Where would I look it up?

Re: help() on stdout.closed

2006-06-21 Thread Fredrik Lundh
Pekka Karjalainen wrote: from sys import stdout help (stdout.closed) > > If I do this, it gives me help on the bool object. that's probably because "sys.stdout.closed" *is* a bool object: >>> sys.stdout.closed False >>> type(sys.stdout.closed) there's no way the reflection system can

Re: help() on stdout.closed

2006-06-21 Thread Jon Ribbens
In article <[EMAIL PROTECTED]>, Pekka Karjalainen wrote: from sys import stdout help (stdout.closed) > > If I do this, it gives me help on the bool object. stdout.closed is a bool. What were you expecting it to show you? -- http://mail.python.org/mailman/listinfo/python-list

help() on stdout.closed

2006-06-21 Thread Pekka Karjalainen
Python 2.4.1 (#1, May 16 2005, 15:19:29) [GCC 4.0.0 20050512 (Red Hat 4.0.0-5)] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> from sys import stdout >>> help (stdout.closed) If I do this, it gives me help on the bool object. Also: >>> stdout.closed.__doc__