[Bug 24478] [xslt 3.0] Static variables and import precedence

https://www.w3.org/Bugs/Public/show_bug.cgi?id=24478

C. M. Sperberg-McQueen <cmsmcq@blackmesatech.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |cmsmcq@blackmesatech.com
         Resolution|---                         |FIXED

--- Comment #2 from C. M. Sperberg-McQueen <cmsmcq@blackmesatech.com> ---
We discussed this issue during the Prague face to face.

There was some consensus that adopting a first-declaration-wins discipline
would solve the problem originally raised.  Regarding multiple declarations we
saw several options:

a) Multiple declarations of a static variable are always an error.

b) Multiple declarations are never an error.

c) The second declaration is an error if and only if it has the same or a
higher import precedence.

d) The second declaration is an error if and only if it has the same or a
higher import precedence and a different value (or an inconsistent value?).

e) The second declaration is an error if and only if it has a different value
(independent of import precedence).

Option c) seemed problematic for stylesheets constructed with a configuration
module declaring static variables which is multiply imported; option e) would
raise an error when a parent module wants to override the setting in an
imported module.

After discussion, the group converged on option d).  This leads to the question
"what counts as the same or a consistent value?"  After further discussion, we
concluded that the rules for identical value in F and O should suffice for this
case.  (There were concerns about the rules for function values, but in a
static context the only function values available are the built-ins, so
identity of name really ought to suffice.)

-- 
You are receiving this mail because:
You are the QA Contact for the bug.

Received on Tuesday, 11 February 2014 09:56:18 UTC