mayah / tinytoml

A header only C++11 library for parsing TOML
BSD 2-Clause "Simplified" License
167 stars 31 forks source link

BREAKING CHANGE: Use std::unordered_map for Table #22

Closed mayah closed 7 years ago

mayah commented 7 years ago

toml specification does not require table is ordered. In usual case, std::unordered_map will have better performance

BUG=#21

veeg commented 7 years ago

I do not believe this is a bug - The specification does not mandate any order, thus keeping it insertion order allows one to output the keys of a table in a nonsensical way.

edit: I'm quite forgetfull - did not support insertion order in the first place.

mayah commented 7 years ago

Note: Insertion order cannot be achieved with std::map (I mentioned it a bit in #21). std::map keeps alphabetical order. Though I wrote this, I don't want to break backward compatibility.

(If I break backward compatibility, I'd like to change Time type first)

mayah commented 7 years ago

abandoned.