<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://www.w3.org/Bugs/Public/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>23944</bug_id>
          
          <creation_ts>2013-11-30 11:43:01 +0000</creation_ts>
          <short_desc>xsl:package/xsl:expose position</short_desc>
          <delta_ts>2014-02-24 16:00:44 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>XPath / XQuery / XSLT</product>
          <component>XSLT 3.0</component>
          <version>Working drafts</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Tony Graham">tgraham</reporter>
          <assigned_to name="Michael Kay">mike</assigned_to>
          <cc>abel.braaksma</cc>
          
          <qa_contact name="Mailing list for public feedback on specs from XSL and XML Query WGs">public-qt-comments</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>96943</commentid>
    <comment_count>0</comment_count>
    <who name="Tony Graham">tgraham</who>
    <bug_when>2013-11-30 11:43:01 +0000</bug_when>
    <thetext>See http://www.biglist.com/lists/lists.mulberrytech.com/xsl-list/archives/201311/msg00107.html and following messages in thread.

I find it odd that in the XSLT 3.0 xsl:package [1]
element, the stylesheet comes between the definitions of what the package
needs and what the package provides:

   (xsl:use-package*, (xsl:stylesheet | xsl:transform), xsl:expose*)

If I had a working implementation of xsl:package, the first thing I would
package is an existing 557-line module [2].  To have to jump between the
top and the bottom of the file when packagising it seems like unnecessary
work compared to allowing xsl:expose before the stylesheet.

For a new user of an existing package, having to jump between the top and
bottom of the package when working out what&apos;s needed for and what&apos;s
provided in the package also seems to me to require unnecessary effort.

[1] http://www.w3.org/TR/xslt-30/#packages
[2] https://github.com/MenteaXML/xslt3testbed/blob/master/xsl/xhtml-tables-fo.xsl</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>98637</commentid>
    <comment_count>1</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2014-01-16 17:41:40 +0000</bug_when>
    <thetext>The WG considered two alternatives:

A. (xsl:expose*, xsl:use-package*, (xsl:stylesheet | xsl:transform))

and

B. (xsl:expose | xsl:use-package)*, (xsl:stylesheet | xsl:transform), (xsl:expose | xsl:use-package)*

We were split down the middle as to whether we preferred A or B, but everyone could live with either.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>98638</commentid>
    <comment_count>2</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2014-01-16 17:44:57 +0000</bug_when>
    <thetext>Revision: the above does not quite reflect everyone&apos;s view. There was a slight preference for A, and we also considered 

C) (xsl:expose | xsl:use-package)*, (xsl:stylesheet | xsl:transform)

which some people people preferred over B. We are interested in Tony&apos;s views on which would be best in his view.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>98790</commentid>
    <comment_count>3</comment_count>
    <who name="Tony Graham">tgraham</who>
    <bug_when>2014-01-20 21:46:25 +0000</bug_when>
    <thetext>Sorry for the delay; I didn&apos;t see the emails for the bug updates and only saw there&apos;d been updates from your meeting minutes.

Option B works for me, since I expect that people will gravitate towards conventions for where to put xsl:use-package and xsl:expose such that most uses would be matched by one of the other patterns anyway -- just like most/many people already put all their xsl:include near the top of their stylesheets just as a matter of good housekeeping -- but I don&apos;t want to presuppose what the convention will be.

Without having been able to use xsl:package yet anyway, my expected sequence would have been:

   xsl:use-package*, xsl:expose*, (xsl:stylesheet | xsl:transform)

but that could be because I&apos;m influenced by the current model and/or by too many years of putting &apos;import&apos; or &apos;#include&apos; statements at the top of files.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>99320</commentid>
    <comment_count>4</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2014-01-28 18:01:54 +0000</bug_when>
    <thetext>The WG decided to go with option B. The editor&apos;s draft (draft R) has been updated.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>