Toml 1.0.0 is out

Posted by on November 19th, 2017

A new version of Toml parser has been released. The main feature of this release is that the parser has been rewritten from scratch for PHP 7.1 and using parser-utils, a set of utilities for writing recursive descent parsers. The support for previous versions of PHP has been abandoned.

The changelog

  • The code has been rewritten from scratch for PHP 7.1.
  • The method parse from Toml class must only be applied to TOML strings. In case of parsing a TOML filename use the new method parseFile.
  • Methods parse and parseFile from Toml class accept a new argument resultAsObject (optional) to return the parsed input as an object (an instance of stdClass).
  • The method addGroup of TomlBuilder class has been deleted.
  • The exceptions have been refactored, so the classes ExceptionInterface, LexerException and RuntimeException have been removed.
  • Added the inner exception when a ParseException is thrown in method parse of class Toml.
  • Fixed bug #13: "Inline sub-tables don't work".
  • Fixed bug #12: "Does not parse a table with an array of tables".
  • Better support for dates as specified in the latest TOML spec. See PR #11.


comments powered by Disqus