[Ohrrpgce] SVN: pkmnfrk/2428 Breaking the ground on my XML idea. for the time being, I'm not hacking

Mike Caron caron.mike at gmail.com
Wed Nov 5 10:41:23 PST 2008


James Paige wrote:
> On Wed, Nov 05, 2008 at 12:03:28AM -0800, subversion at HamsterRepublic.com wrote:
>> pkmnfrk
>> 2008-11-05 00:03:27 -0800 (Wed, 05 Nov 2008)
>> 467
>> Breaking the ground on my XML idea. for the time being, I'm not hacking the OHR directly. Instead, I'm going to work on a separate "test" program.
>>
>> The main reason is because using libxml adds three DLLs as dependencies, and I'm going to try and make them all static libraries, or at least roll them into one DLL.
>>
>> I assume this is not such a big deal on Linux, since Linux users are used to having to apt-get a bunch of stuff before trying new things out, right? :P
> 
> I was reading up on the differences between XML, YAML and JSON. I really 
> liked the minimalism of those other formats. XML really is astonishingly 
> bulky.

Truthfully, I'd never heard of YAML until this very moment. However, I 
glossed over the spec to get an idea of it, and here are my thoughts, 
and why I like XML.

YAML: It uses indentation for block levels. As I'm sure I've expressed 
before, I dislike this, due to the possibility of screwing it up by 
having the wrong tab settings as the last guy. Indentation is good, 
delineation by indentation is bad, IMO. It also prevents me from copying 
one block from any random place and popping it in wherever I want 
without fixing the indentation. (altogether, this is also why I 
personally can't stand python)

JSON: If you look at the example page 
(http://www.json.org/example.html), then you'll notice something 
disconcerting. Barring the last example (a servlet definition), the XML 
versions of all those examples are more readable. It may not be as 
concise, but it... I dunno, it looks better to me. Also, the fact that I 
can't see at a glance which brace matches which block bugs me, slightly.

XML: Yes, XML is the bulkiest of the lot. But, it's the most mature 
format as well. And, lots of tool support is available. But, the thing 
that really sells me on XML is that I could, in theory, write an XSLT 
stylesheet, attach it to my textbox document, and get a preview of every 
textbox in my game, for example. Or, also in theory, I could embed every 
data lump in one document (if I ever decided that was necessary or a 
good idea).

Lastly, for the purposes of OHR development, XML is the only format in 
the bunch that has a library included with the compiler. For the other 
formats, I'd have to translate their headers into FB, which may or may 
not be impossible (it likely is possible, but it's still a lot of work).


More information about the Ohrrpgce mailing list