This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 1542 - [FS] editorial: 3.1.1 Static Context
Summary: [FS] editorial: 3.1.1 Static Context
Status: CLOSED FIXED
Alias: None
Product: XPath / XQuery / XSLT
Classification: Unclassified
Component: Formal Semantics 1.0 (show other bugs)
Version: Last Call drafts
Hardware: All All
: P2 minor
Target Milestone: ---
Assignee: Jerome Simeon
QA Contact: Mailing list for public feedback on specs from XSL and XML Query WGs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-07-10 23:30 UTC by Michael Dyck
Modified: 2007-02-25 23:13 UTC (History)
0 users

See Also:


Attachments

Description Michael Dyck 2005-07-10 23:30:02 UTC
3.1.1 Static Context

"If analysis of an expression relies on some component of the static
context that has not been assigned a value, a static error is raised.
This constraint is formalized in [3.3 Error Handling]."
    Section 3.3 doesn't have that rule any more.

"The statEnv.xpath1.0_compatibility environment"
"The statEnv.default_elem_namespace environment"
[etc]
    Section 2.1.4 says:
    "An environment is a dictionary that maps a symbol ... to an object."
    so it's contradictory (as well as just odd) to refer to these
    non-dictionary properties as environments.

"statEnv.funcType"
"define function QName (Type1, ..., Typen) return Type"
    You need a non-terminal/pattern for this construct.
    The rules in section 4.1.5 use FunctionDecl, which is something else.
    Also, they say "declare" rather than "define", and "expanded-QName"
    rather than "QName".

inference rule
    Expr* is incorrect. Expr* does not occur anywhere.
    Note that a QueryBody is just an Expr.

    And there should presumably be a semicolon between URI and Expr.

    And the "statEnv |- Expr" syntax (without ": Type") is not used any
    more, that I can find.

    You might want to use a different example, since this one doesn't
    actually occur.
Comment 1 Michael Dyck 2005-07-11 04:56:11 UTC
(Also...)

"statEnv.namespace"
    How would it come about that statEnv.namespace maps a prefix to the
    null namespace?
Comment 2 Jerome Simeon 2005-10-24 20:19:52 UTC
Fixes as suggested. Kept the example.
- Jerome
Comment 3 Michael Dyck 2006-09-18 06:03:44 UTC
Re the example inference rule:
    You changed Expr* to Expr, but the prose still refers to
    "a/the sequence of expressions"

And re statEnv.namespace:
    I still don't see how statEnv.namespace could come to
    map a prefix to the null namespace.
Comment 4 Jerome Simeon 2006-10-19 23:33:48 UTC
Fixed the text around the example.

I'm not completely sure about the NULL namespace for that part of the context,
but would rather not make a change at this point unless of a specific bug.

- Jerome
Comment 5 Michael Dyck 2006-12-07 08:36:57 UTC
(In reply to comment #4)
> Fixed the text around the example.

Not entirely. There's still the phrase "a sequence of expressions".
Comment 6 Jerome Simeon 2007-01-16 17:53:16 UTC
Fixed. Replaced 'a sequence of expressions' by 'an expression'.

- Jerome