]> matita.cs.unibo.it Git - helm.git/blobdiff - helm/style/reals.xsl
added support for compressed files
[helm.git] / helm / style / reals.xsl
index 982d4ed21746de26a7c162146cb4b91a5670a415..7a1a0d1839de749ac5c4e0a23491d0f565f00393 100644 (file)
@@ -63,7 +63,7 @@
 
 
 
-<!-- Unary Operations -->
+<!-- Unary Operations and power -->
 
 <xsl:template match="APPLY[CONST[
  attribute::uri='cic:/Coq/Reals/Rdefinitions/Ropp.con' or
@@ -84,7 +84,7 @@
          <xsl:value-of select="'factorial'"/>
         </xsl:when>
         <xsl:when test="CONST/@uri='cic:/Coq/Reals/Rbase/Rsqr.con'">
-         <xsl:value-of select="'root'"/>
+         <xsl:value-of select="'power'"/>
         </xsl:when>
        </xsl:choose>
       </xsl:variable>
@@ -98,6 +98,9 @@
         </xsl:attribute>
        </xsl:element>
        <xsl:apply-templates select="*[2]" mode="noannot"/>
+       <xsl:if test="string($elem)='power'">
+        <m:cn><xsl:value-of select="*[2]/@value"/></m:cn>
+       </xsl:if>
       </m:apply>
      </xsl:when>
      <xsl:otherwise>
          <xsl:attribute name="definitionURL">
           <xsl:value-of select="CONST/@uri"/> 
          </xsl:attribute>
+         <xsl:attribute name="helm:xref">
+          <xsl:value-of select="CONST/@id"/>
+         </xsl:attribute>
         </m:minus>
-        <xsl:attribute name="helm:xref">
-         <xsl:value-of select="CONST/@id"/>
-        </xsl:attribute>
         <m:cn>1</m:cn>
        </m:apply>
       </m:apply>
            </xsl:attribute>
           </m:limit>
           <m:bvar>
-           <m:ci><xsl:call-template name="insert_subscript"><xsl:with-param name="node_value"><xsl:value-of select="LAMBDA/target/@binder"/></xsl:with-param></xsl:call-template></m:ci>
+           <m:ci>
+            <xsl:call-template name="insert_subscript"><xsl:with-param name="node_value"><xsl:value-of select="LAMBDA/target/@binder"/></xsl:with-param></xsl:call-template>
+           </m:ci>
           </m:bvar>
           <m:lowlimit>
            <xsl:apply-templates select="*[5]" mode="noannot"/>
         </xsl:when>
         <xsl:otherwise>
          <m:apply helm:xref="{@id}">
-          <m:limit/>
+          <m:limit>
+            <xsl:attribute name="definitionURL">
+             <xsl:value-of select="CONST/@uri"/> 
+            </xsl:attribute>
+            <xsl:attribute name="helm:xref">
+             <xsl:value-of select="CONST/@id"/>
+            </xsl:attribute>
+           </m:limit>
           <m:bvar>
            <m:ci>$x</m:ci>
           </m:bvar>
        <xsl:choose>
         <xsl:when test="name(*[2]) = 'LAMBDA'">
          <m:apply helm:xref="{@id}">
-          <m:diff >
+          <m:diff>
            <xsl:attribute name="definitionURL">
             <xsl:value-of select="CONST/@uri"/> 
            </xsl:attribute>
 </xsl:template>
 
 </xsl:stylesheet>
+
+