Re: Why less emphasis on private data?

2007-01-07 Thread Ben Artin
In article <[EMAIL PROTECTED]>, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > Coming from a C++ / C# background, the lack of emphasis on private data > seems weird to me. I've often found wrapping private data useful to > prevent bugs and enforce error checking.. > > It appears to me (perhaps

Re: checking one's type

2007-01-05 Thread Ben Artin
In article <[EMAIL PROTECTED]>, belinda thom <[EMAIL PROTECTED]> wrote: > I've been using the following hack to determine if a type is > acceptable and I suspect there is a better way to do it: > > e.g. > > if type(s) == type("") : > print "okay, i'm happy you're a string" > > If anyone

Re: doctesting

2007-01-02 Thread Ben Artin
In article <[EMAIL PROTECTED]>, belinda thom <[EMAIL PROTECTED]> wrote: > I'd like to write a tester script that I can place in one place (say > ~/bin/python/tester.py) and then have it visible to me at the cmd- > line (by setting the path variable appropriately). I have had no > luck in ge