stan-dev/stan — pull request #494 by bob-carpenter (2014-01-16 21:02:18+00:00)
Title: Hotfix/v2.1.1

*Summary:* Plugs remaining memory leak, completing fix for issue #472.

*Intended Effect:* Fix leak in `log_softmax` by using correct operator new in `agrad::vari::operator new`.

I did not need to fix the other possible leaks called out in issue #472 because they were either (a) explicitly qualified to use `agrad::vari::operator new`, or (b) were using an unqualified version within a class extending `agrad::vari`

#### How to Verify:

Run the tests. To really convince yourself, unplug the leak and see the tests fail with not enough memory allocated on our auto-diff stack because it's allocated on heap.

#### Side Effects:

None.

#### Documentation:

Not user facing. I documented the tests themselves a bit.

#### Reviewer Suggestions:

Daniel, because he's going to want to look at the tests.