xproc / 3.0-specification

A community-driven effort to define an XProc 3.0 specification (formerly 1.1)
http://spec.xproc.org/
33 stars 10 forks source link

Scoping of step names #1104

Closed ndw closed 3 months ago

ndw commented 3 months ago

The spec says:

The scope of the names of the steps (the values of the step’s name attributes) is determined by the environment of each step. In general, the name of a step, the names of its sibling steps, the names of any steps that it contains directly, the names of its ancestors, and the names of the siblings of its ancestors are all in a common scope. All steps in the same scope must have unique names: it is a static error (err:XS0002) if two steps with the same name appear in the same scope.

But I don't think the environment section actually says anything useful about step names.

I think this is editorial, but I'm not sure exactly how to remedy it. We could try to add step names to the environment, or we could change this paragraph in the spec to read:

The scope of the names of the steps (the values of the step’s name attributes) is the step on which the name appears, the names of its sibling steps, the names of any steps that it contains directly, the names of its ancestors, and the names of the siblings of its ancestors. All steps in the same scope must have unique names: it is a static error (err:XS0002) if two steps with the same name appear in the same scope.

xml-project commented 3 months ago

I think the proposed wording is much better than the previous one.