Commit Graph

78 Commits

Author SHA1 Message Date
eanderton 2811a1a3c9 Added QueryResult and patched bugs
QueryResult now stores result items and position data, which aligns more
strongly with the rest of the library features than a plain
[]interface[}.  The design of the parser_test unittest was revised to
use array/map/scalar serialization (like match_test), since Go 1.3
redesigned maps to randomly order their keys. Since naive comparisons of
map data is now no longer possible, the unittest now sorts map
keys:value combinations.

* Patched a bug where getPosition("") was returning an invalid Position
* Revised parser_test to use serialization for comparisons for Go 1.3
2014-09-09 22:31:41 -04:00
eanderton 7c63fff960 Added Position Support to TomlTree
TomlDocument provides an optional TOML processing path where position
informaiton is stored alongside a TomlTree.
* Added Position struct
* Revised TomlTree to contain position data
* Added tomlValue to bind positions to values
* Revised parser to emit position data
* Revised token to use new Position struct
* Added tests for new functionality
* Bugfixed table array duplicate key handling
* Applied gofmt to all code
2014-08-26 21:00:41 -04:00
Thomas Pelletier 65684e6bb0 Fixes #20 : Creation of subgroup in table arrays 2014-08-14 10:12:39 +02:00
eanderton aa194b5c41 Revised error message in parser test 2014-08-06 20:30:30 -04:00
eanderton 14e2d94bdd Added missing test entry 2014-08-06 20:28:44 -04:00
eanderton 1f8a8cbc06 Added error context for parsing of subtrees 2014-08-06 08:20:53 -04:00
eanderton 6db660fed5 Revised error formatting, fixed tests 2014-08-06 08:15:05 -04:00
eanderton 7d9a3c25bd Revised error reporting 2014-08-06 07:34:01 -04:00
eanderton c9ea292f59 Additional formatting 2014-07-07 21:08:57 -04:00
eanderton c8b5633273 Group array support; ToString() support 2014-07-07 20:48:29 -04:00
Thomas Pelletier a4d623ad05 Fix implicit declaration 2013-12-10 19:29:01 +01:00
Thomas Pelletier 3085454477 Don't allow duplicate keys 2013-12-10 17:50:59 +01:00
Thomas Pelletier 01609e0ab7 Add some tests for nested empty arrays 2013-12-10 17:46:30 +01:00
Thomas Pelletier 278c4d97ec Don't allow floats starting with a dot 2013-12-10 17:17:15 +01:00
Thomas Pelletier c743c90315 Don't allow empty intermediate tables 2013-12-10 16:23:53 +01:00
Thomas Pelletier 8081f3cc09 Don't allow tables to be redefined 2013-12-10 16:10:26 +01:00
Thomas Pelletier 72f17747a0 Prevent mixed types in arrays 2013-12-10 15:45:50 +01:00
Thomas Pelletier be268e4049 Include @cmars tests 2013-12-09 17:25:31 +01:00
Thomas Pelletier 558a227433 Run gofmt 2013-03-26 12:10:14 +01:00
Thomas Pelletier edc78bc0bf Add test for newlines in arrays 2013-03-26 11:52:42 +01:00
Thomas Pelletier 329092b812 Implement escapable characters in strings 2013-03-26 11:45:36 +01:00
Thomas Pelletier 8c48e59100 Develop ParseFile test 2013-03-26 11:35:18 +01:00
Thomas Pelletier 8a5d380286 Fix strings lexing and add a few tests 2013-03-26 10:53:49 +01:00
Thomas Pelletier 21a8fb6ee0 Add LoadFile 2013-03-22 17:14:16 +01:00
Thomas Pelletier 0d489ff32c Add couple of tests for arrays 2013-03-22 15:27:00 +01:00
Thomas Pelletier 2bd1eb4f21 Add tests for errors (fixes #5) 2013-03-22 15:23:53 +01:00
Thomas Pelletier 183bbe2aa9 Return an error instead of panicking 2013-03-22 15:03:51 +01:00
Thomas Pelletier 8783fed844 Readd source files. I need coffee now 2013-02-25 10:57:12 +01:00