Bug 865960 - JS OOM should throw instead of silently stopping execution (r=billm)

--HG--
extra : rebase_source : a9c64989310ef96923a74fd3ee902aae59805aca