Re: Structured Headers: URI type (#782)

On 09.05.2019 13:35, Michael Sweet wrote:
>> On May 9, 2019, at 2:02 AM, Poul-Henning Kamp <phk@phk.freebsd.dk> wrote:
>> ...
>> PS: Reminds me: Why does ABNF not have an 'import' facility ?
>>
>> This would be much clearer:
>>
>>  import token68 from [RFC7235]

Has been suggested many times, but not specced (afair).

In HTTPbis, we use prose rules for that, such as

 > uri-host = <host, see [RFC3986], Section 3.2.2>

That at least makes the ABNF complete.


>> Than (from 7540):
>>
>>  The ABNF [RFC5234] production for "token68" is defined in
>>  Section 2.1 of [RFC7235].
>
> I've often wondered why the IETF doesn't publish the ABNF for RFCs someplace, e.g., "https://tools.ietf.org/abnf/rfcNNNN", so that such imports are not only possible but then automated tools can pull an official ABNF (with any typographical corrections applied that might slip through the RFC publication process) for use in validation, etc.
>
> We started doing that for IPP specifications several years ago and it has been very useful in validating attribute values, etc.

For many specs, you can simply extract it from the XML source.

For instance, we do that as part of building the HTTP specs, see
<https://github.com/httpwg/http-core/blob/master/httpbis.abnf>.

Best regards, Julian

Received on Thursday, 9 May 2019 12:21:19 UTC