facebook/jcommon — pull request #5 by twilliamson (2012-11-14 01:39:06+00:00)
Title: Fix stack overflow in StaticModelUtil.weightsToProbabilities

Converts StaticModelUtil.weightsToProbabilities() recursion into a loop. Also adds the ability to limit the number of iterations, and makes use of that limit in StaticModel and SortedStaticModel.

Strictly speaking, this is not backwards compatible, since StaticModel and SortedStaticModel no longer have exactly the same state.