Vedran Čačić <ved...@gmail.com> added the comment:

My reading of the documentation says floats are only tentatively supported. The 
main text of the documentation says the values are supposed to be integers. 
Even the note mostly talks about negative values, the floats are mentioned in 
only one item. (And in that item, it says the value type should support 
addition and subtraction. I think it's not too big a stretch to stipulate it 
should support them accurately.:)

But whatever you do about total (cached property was just my idea to enable 
implementation of a probability distribution as a view on a Counter), it's 
obvious from the documentation that the output of normalize is _not_ a Counter. 
It might be a subclass, but I'd rather it be a completely separate class. The 
API intersection is not really that fat.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue25478>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to