zidizei/toml-php — pull request #1 by laurent22 (2013-03-29 03:19:18+00:00)
Title: Bug fix for int value of "0"

Hello,

The current implementation of `Toml::parseValue()` was incorrectly setting int values of `0` to `null`. This is because `empty("0")` (surprisingly) returns `true`. The fix is to check with strict equality with `""` instead.

Also, I took the liberty to change the way the parser handles empty values. It is now throwing an `UnexpectedValueException` since empty values are currently not allowed by the spec. And looking at the [discussion](https://github.com/mojombo/toml/issues/146) on the issue page it doesn't seem likely it is going be allowed.

I've also added the tests for these two changes.

Many thanks for your library by the way, and hope the fix is useful.

Best,

Laurent