- From: Richard Smith <richard@ex-parrot.com>
- Date: Sun, 21 May 2017 14:47:01 +0100 (BST)
- To: public-rdfa@w3.org
- Message-ID: <alpine.LRH.2.02.1705211414230.31059@sphinx.mythic-beasts.com>
What form of BNF is used in the grammar productions in the RDFa Core 1.1 spec? It's possible I'm missing something, but I cannot see it stated. My undestanding is that most XML-based standards use, explicitly or more frequently implicitly, the form of Extended BNF defined in §6 of the XML specification (either 1.0 or 1.1). However that isn't the case in RDFa Core 1.1, e.g. in §6, there's the production: curie ::= [ [ prefix ] ':' ] reference The use of square brackets for productions that optionally occur is not allowed in XML's EBNF which would have this rule expressed thus: curie ::= ( prefix? ':' )? reference More confusingly, the definition of 'reference' in §6 uses a '/' to denote alternatives, while the definitions of 'whitespace' in §5.2 and 'termChar' in §7.4.3 use '|'. My best guess is that the grammar productions in §5 and §7 are using XML's EBNF, while those in §6 'CURIE Syntax Definion' are written using IETF's ABNF as defined in RFC 2234. There's a certain logic to this. Things relating to URLs are generally expressed in ABNF because most of the standards are IETF RFCs; things relating to XML are generally expressed in EBNF because most of the standards are W3C Recommendations. So it made sense for the 'CURIE Syntax 1.0' note to use ABNF. But now that this has been folded into the RDFa Core spec, it seems confusing to have both BNF syntaxes in use in the same document. Can I suggest that an errata is issued, either to convert the four productions in §6 to use XML's ENBF, or to add a note to the document stating that §6 uses ABNF while the result of the document uses EBNF? Richard
Received on Sunday, 21 May 2017 13:50:03 UTC