tags:

views:

70

answers:

3

I'm not looking for a comparison of the relative merits of YAML or JSON over each other, I'm purely looking for something that is supported by many languages and has stable implementations.

Also another plus would be to know which has the libraries that do not have huge dependency trees requiring other libraries.

+3  A: 

Both YAML and JSON have stable libraries for many different languages and all of the most popular languages have good support for both. JSON is the simplest of the two to implement so it has slightly more support.

If you want to get a very rough idea of stable language support you can compare the lists of the libraries linked from the official homepages:

YAML

  • C/C++
  • Java
  • Python
  • Ruby
  • Perl Modules
  • C#/.NET
  • PHP
  • OCaml
  • Javascript
  • Actionscript
  • Haskell

JSON

  • ASP
  • ActionScript
  • C
  • C++
  • C#
  • ColdFusion
  • D
  • Delphi
  • E
  • Eiffel
  • Erlang
  • Fantom
  • Flex
  • Go
  • Haskell
  • haXe
  • Java
  • JavaScript
  • Lasso
  • Lisp
  • LotusScript
  • Lua
  • Objective C
  • Objective CAML
  • OpenLaszlo
  • Perl
  • PHP
  • Pike
  • PL/SQL
  • PowerShell
  • Prolog
  • Python
  • R
  • REALbasic
  • Rebol
  • RPG
  • Ruby
  • Squeak
  • Tcl
  • Visual Basic
  • Visual FoxPro
Mark Byers
Wow, I guess YAML not being supported in Erlang counts it out for me then! Thanks
Zubair
Well there is this, found from Google: http://code.google.com/p/yaml-erlang/ ... I have no idea how stable that is though.
Mark Byers
Yes, I see why you left out Yaml from the list now. Thanks for the link. It seems to be quite immature and experimental YAML parser for Erlang
Zubair
+2  A: 

YAML is a superset of JSON - therefore if a library supports YAML, it also supports JSON.

Joe Gauterin
So that's why there is more JSON parsers! :)
Zubair
A: 

I'd have to be JSON... Because the situation in the world of YAML is a mess. There are border cases, where every library interprets something differently from the others. That's what you get with ad hoc "specifications"...

See, for example, this rant. And there are plenty more of those out there.

bart