I hate new DUB config format

Ola Fosheim Grøstad via Digitalmars-d digitalmars-d at puremagic.com
Sun Nov 29 09:44:00 PST 2015


On Sunday, 29 November 2015 at 17:25:04 UTC, Poyeyo wrote:
> Looking at the two main D competitors, go uses json and rust 
> uses a proprietary format.

Tangential to your point, but both Go and Rust suffers from "our 
policy is to be weird" in many ways that are "off-putting", and D 
also suffers from a rather broad stroke of not-invented-here.

Wouldn't it be refreshingly progressive if D just picked _one_ 
canonical format for _all metadata_ that isn't D code as a policy?

Something flexible like XML? That way you could wrap up all meta 
for an entire project and extract information from it using 
widespread standards like XPath and XQuery.

One problem with JSON is that it depends on meta information 
being relayed in HTTP headers. It is not a file format. Given a 
bunch of JSON files, you can't really tell what they are...

JSON is suitable as an alternative formulation, but not for a 
canonical format. Both JSON and YAML can be translated into 
corresponding XML too. Just provide tooling for JSON->XML and 
YAML->XML.



More information about the Digitalmars-d mailing list