[me]
> > (c) The right place to do the overflow checks is in the API wrappers,
> > not in the integer types.

[Keith Dart]
> That would be the "traditional" method.
> 
> I was trying to keep it an object-oriented API. What should "know" the
> overflow condition is the type object itself. It raises OverFlowError any
> time this occurs, for any operation, implicitly. I prefer to catch errors
> earlier, rather than later.

Isn't clear to me at all. I might compute a value using some formula
that exceeds 2**32 in some intermediate result but produces an
in-range value in the end. That should be acceptable as an argument. I
also don't see why one approach is more OO than another; sounds like
you have a case of buzzworditis. :-)

-- 
--Guido van Rossum (home page: http://www.python.org/~guido/)
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to