Pragma strawman

I've been involved with other activities today, so I'm behind on email, but 
I did have time to draft a strawman grammar for pragmas. The rule for 's' 
is changed:


            -s: (whitespace; comment; pragma)*.
       comment: -"{", ~["*"], (cchar; comment)*, -"}".
        -cchar: ~["{}"].
        pragma: -"{*", processor, -" ", (cchar; comment; pragma)*, -"}".
    @processor: ~[" {}"]*.


For example:


    {*ixml=http://invisiblexml.org/ixml This is a pragma}
    {And this is a comment}


Output:


    <pragma processor='ixml=http://invisiblexml.org/ixml'>This is a 
pragma</pragma>
    <comment>And this is a comment</comment>


The @processor value SHOULD contain a URI to identify the processor 
addressed, and MAY contain an identifier to shorten later pragmas:


    {*ixml this is a later pragma to the same processor}


The structure of body text of any pragma is defined by the processor it is 
addressed to.


Steven

Received on Wednesday, 12 January 2022 21:38:01 UTC