[Doc-SIG] formalizing StructuredText

Tony J Ibbs (Tibs) tony@lsl.co.uk
Fri, 16 Mar 2001 16:55:07 -0000

Edward D. Loper wrote:
> I think that there are two ideas of what STminus does that
> are floating around:
>     1. it's a "simple," "clean" version of ST
>     2. it's an intersective subset of STNG and STpy
> Unfortunately, (1) and (2) are really mutually exclusive..  If STminus
> is to *actually* be an intersective subset of STNG and STpy, then
> it needs to take all the quirks of each into account, so it can
> make strings where STNG and STpy disagree undefined..

Hmm - I think that's got to be for you to decide. It *may* be that both
are sufficiently useful to want to have (I'd go for that), in which case
you get to (a) choose two names and (b) choose which you do first.

You *could* call the "minimal compatibility" one STminusminus, of

> > > > >        * What do you do with things like::
> > > > >
> > > > >            This *is "too* confusing":http://some.url
> > >
> > > Perhaps I should rephrase that.  What should a *parser* do?
> > > I guess "die" is a good answer, though it sounds like you might
> > > prefer something along the lines of "erase their hard drive." :)
> Hm.  let's try once more.  What answer *should* a parser
> give?  ('error' is a possible answer)

Damn, he's being persistent. Don't you just hate that.


No, seriously, the only way (with RE technology) that you are going to
detect an error there is by adding that pattern to your "long list of
error patterns" RE. To an RE-using system that looks for things going
'*..*' and things going '"..":<url>', there will simply be no
ambiguity - the one that finds it first will win, leaving odd bits of
"definitely not markup, guv" text lying strewn around it. Specifically,
the above would *either* be::

	plain: 'This '
	emph:  'is "too'
	plain: ' confusing":http://some.url'

*or* it would be::

	plain:   'This *is '
	urltext: 'too* confusing'
	         [url: http://some.url]

In neither case is there any ambiguity - it just depends on the order in
which things are done. It's because it's done with REs, you see - there
isn't any *real* understanding of document structure going on.

All the poor user can do is stare at the result, and wonder why it isn't
what they expected. Sounds like some compilers I've known.

Tony J Ibbs (Tibs)      http://www.tibsnjoan.co.uk/
"How fleeting are all human passions compared with the massive
continuity of ducks." - Dorothy L. Sayers, "Gaudy Night"
My views! Mine! Mine! (Unless Laser-Scan ask nicely to borrow them.)