Re: [whatwg] HTMLLinkElement.disabled and HTMLLinkElement.sheet behavior

On Tue, 28 Aug 2012, Boris Zbarsky wrote:
> On 8/28/12 1:27 PM, Ian Hickson wrote:
> > The latter. The blocking only affects scripts that are "prepare the 
> > script"ed by the "top-level" parser, not a reentrant parser.
> 
> OK.  I see.
> 
> This requires the "blocked by" state to live on an individual script 
> instead of on the document, right?

<script> elements have a ton of state, but for this particular issue, the 
state that is needed is:

 - presence or absence of src="" attribute
 - "parser-inserted" flag
 - whether the parser in question was an XML parser or HTML parser
 - parser's script nesting level while "prepare the script" is running
 - whether the parser's Document has a "style sheet that is blocking scripts"

Relative to before this edit, the only addition is the check of the 
parser's "script nesting level"; you already had to have all the script 
element state (in particular, you already had to keep track of which 
parser created the element); the parser's "script nesting level", and the 
element's "pending parsing-blocking script" mechanism and the "ready to be 
parser-executed" flag, are not new.

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'

Received on Tuesday, 28 August 2012 17:47:03 UTC