Re: [heycam/webidl] Add namespaces (#121)

> +            namespace object are described in <a href='#namespace-object'>section <?sref
> +            namespace-object?></a> <?sdir namespace-object?>.
> +          </p>
> +
> +          <div id='namespace-object' class='section'>
> +            <h4>Namespace object</h4>
> +
> +            <p>
> +              The namespace object for a given <a class='dfnref' href='#dfn-namespace'>namespace</a>
> +              <var>namespace</var> and Realm <var>realm</var> is created as follows:
> +            </p>
> +
> +            <ol class='algorithm'>
> +              <li>
> +                Let <var>namespaceObject</var> be
> +                ! <a>ObjectCreate</a>(the <a>%ObjectPrototype%</a> of <var>realm</var>).

I think this syntax is terrible, as I've pointed out before.  The fact that it's (1) non-obvious and (2) not linkified to point to its definition makes it _really_ hard to get into reading a spec without reading a bunch of front matter that hides the syntax definition quite well.

But also, nothing in Web IDL links to that section of the ES spec, so people would have no idea you're doing that anyway.  This would be a bare minimum requirement for using this syntax, because then you could at least make the (laughable, imo, but technically correct) claim that "if you had read the entire Web IDL spec starting at the very beginning and to this point, and followed all the links from it and read those too, you would know what this syntax means in this spec".  A slight step up would be explicitly saying that '!' and '?" mean what they mean in `#sec-algorithm-conventions`, or that all algorithms are written using those conventions (and hence the reader of Web IDL should read them) or something.

---
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/heycam/webidl/pull/121/files/70ba6d9c213e2b05cf0d8b3ebd14ce9a4583f4c6#r63219245

Received on Friday, 13 May 2016 17:21:22 UTC