laziness, impatience, and hubris | |
PerlMonks |
Re^2: Converting from Storable to YAMLby moritz (Cardinal) |
on Jan 21, 2011 at 21:57 UTC ( [id://883627]=note: print w/replies, xml ) | Need Help?? |
JSON and YAML fill two different needs. JSON is meant for data interchange between different languages, and can only handle the most basic data types (arrays, hashes, strings, numbers and undef, and only tree structures). YAML on the other hand also handles blessed references and self-referential constructs (ie. arbitrary object graphs). No wonder that JSON modules are faster than YAML modules, they do way less. When the feature set of JSON is sufficient, choosing JSON over YAML is a good idea (simpler format, easier to implement right, less chance of ambiguity). If not, not. There's also JSYNC, which tries to combine the advantages of both formats. I don't know how mature it is today.
In Section
Seekers of Perl Wisdom
|
|