On Friday 26 January 2001 03:10, you wrote:
> I finished the first version of the Unified MSX Format
> syntax verifier. You can get it in the address:
>
> http://www.lsi.usp.br/~ricardo/msx/inicheck.zip
I noticed you are using a callback mechanism to feed information to the
program using the parser. Because there is no fixed order of statements in
the INI file, this may be inconvenient. For example, a "Banksize=8" may
appear after "Initial[4000]=0" and an emulator wouldn't know how much memory
to initialize to block 0 before the bank size is known.
We could solve this by including the sequence of INI statements in the
standard. But I don't like that much, it will make the standard larger, take
more effort from people writing INI files and will demand more error checking
from the parser.
A different option is to make the parser build a data structure and the let
the emulator use that data structure to initialise itself. First, the entire
INI file will be parsed and stored in the data structure, then the emulator
would call getField("GameID") which would return the value of GameID etc.
There should also be a way to iterate through multiple instances of the same
statement, like Initial and Register.
By the way, I think the "Register[5000/07FF]=4000" syntax is a bit confusing
since there is also the "Name[en]=Penguin Adventure" syntax and there is
hardly any similarity between "5000/07FF" and "en". Maybe something like
"Register=5000/07FF->4000" is better.
You licensed the source under GPL. This does mean that it can only be used in
projects that have a license compatible with GPL. For example fMSX does not
comply, because the fMSX-Windows code is not public and the fMSX license
doesn't require people to make code of ports public. Are you aware of this?
I don't mind, there is sense in "you shouldn't use open source code if you're
not willing to open your own source", but it does mean that this
implementation cannot be used by all emulator authors without them changing
their licenses and opening up their source.
Bye,
Maarten
--
For info, see http://www.stack.nl/~wynke/MSX/listinfo.html