? xsl/doxygen/.doxygen2boostbook.xsl.swp
Index: xsl/doxygen/doxygen2boostbook.xsl
===================================================================
RCS file: /cvsroot/boost/boost/tools/boostbook/xsl/doxygen/doxygen2boostbook.xsl,v
retrieving revision 1.38
diff -u -p -r1.38 doxygen2boostbook.xsl
--- xsl/doxygen/doxygen2boostbook.xsl	14 Mar 2007 22:33:58 -0000	1.38
+++ xsl/doxygen/doxygen2boostbook.xsl	2 Apr 2007 22:05:04 -0000
@@ -46,6 +46,7 @@
 
   <xsl:key name="compounds-by-kind" match="compounddef" use="@kind"/>
   <xsl:key name="compounds-by-id" match="compounddef" use="@id"/>
+  <xsl:key name="members-by-id" match="memberdef" use="@id" />
 
   <xsl:strip-space elements="briefdescription detaileddescription"/>
 
@@ -412,6 +413,16 @@ Cannot handle compounddef with kind=<xsl
     </xsl:if>
   </xsl:template>
 
+  <xsl:template match="sectiondef" mode="toplevel">
+    <xsl:param name="in-file" select="''"/>
+
+    <xsl:apply-templates mode="toplevel"
+                         select="memberdef[generate-id() =
+                                 generate-id(key('members-by-id', @id))]">
+      <xsl:with-param name="in-file" select="$in-file"/>
+    </xsl:apply-templates>
+  </xsl:template>
+
   <xsl:template match="memberdef" mode="toplevel">
     <xsl:param name="with-namespace-refs"/>
     <xsl:param name="in-file"/>
@@ -447,6 +458,19 @@ Cannot handle compounddef with kind=<xsl
           <xsl:apply-templates select="detaileddescription" mode="passthrough"/>
         </macro>
       </xsl:when>
+
+      <xsl:when test="@kind='function'">
+        <xsl:call-template name="function" />
+      </xsl:when>
+
+      <xsl:when test="@kind='typedef'">
+        <xsl:call-template name="typedef" />
+      </xsl:when>
+
+      <xsl:otherwise>
+        <xsl:message>Cannot handle toplevel memberdef element with
+        kind=<xsl:value-of select="@kind"/></xsl:message>
+      </xsl:otherwise>
     </xsl:choose>
   </xsl:template>
 
@@ -665,6 +689,12 @@ Cannot handle compounddef with kind=<xsl
       <xsl:when test="@kind='user-defined'">
         <xsl:apply-templates/>
       </xsl:when>
+      <xsl:when test="@kind=''">
+        <xsl:apply-templates select="memberdef[generate-id() =
+                                     generate-id(key('members-by-id', @id))]">
+          <xsl:with-param name="in-file" select="$in-file"/>
+        </xsl:apply-templates>
+      </xsl:when>
       <xsl:otherwise>
         <xsl:message>
 Cannot handle sectiondef with kind=<xsl:value-of select="@kind"/>      

