This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author ethan.furman
Recipients cool-RR, eric.smith, ethan.furman, josh.r, pitrou, r.david.murray, rhettinger, scoder, serhiy.storchaka, steven.daprano
Date 2014-10-01.17:35:49
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1412184949.95.0.58962778712.issue22515@psf.upfronthosting.co.za>
In-reply-to
Content
I have to disagree.  The intent is clearly expressed in the docs [1].  However, if I have a need to deal with partial amounts (say, 2.5 apples because I gave half of one to my horse ;), Counter will still work with that:

  --> treats = Counter({'carrots':12, 'apples':3, 'sugar_cubes':100})
  --> treats
  Counter({'sugar_cubes': 100, 'carrots': 12, 'apples': 3})
  --> treats['apples'] -= 0.5
  --> treats
  Counter({'sugar_cubes': 100, 'carrots': 12, 'apples': 2.5})

At least, it will until we fix that bug.  ;)
History
Date User Action Args
2014-10-01 17:35:50ethan.furmansetrecipients: + ethan.furman, rhettinger, pitrou, scoder, eric.smith, steven.daprano, r.david.murray, cool-RR, serhiy.storchaka, josh.r
2014-10-01 17:35:49ethan.furmansetmessageid: <1412184949.95.0.58962778712.issue22515@psf.upfronthosting.co.za>
2014-10-01 17:35:49ethan.furmanlinkissue22515 messages
2014-10-01 17:35:49ethan.furmancreate