preproc/template: Add param-sym-value/@ignore-missing
* src/current/include/preproc/template.xsl (preproc:gen-param-value)[lv:param-sym-value]: Suppress warning for missing symbol and yield empty string if `@ignore-missing='true'`.master
parent
afc1a2038a
commit
5b5055db6d
|
@ -1251,18 +1251,21 @@
|
|||
|
||||
<xsl:choose>
|
||||
<xsl:when test="not( $sym-value ) or $sym-value = ''">
|
||||
<xsl:message>
|
||||
<xsl:text>warning: unable to find `@</xsl:text>
|
||||
<xsl:value-of select="$value" />
|
||||
<xsl:text>' for symbol `</xsl:text>
|
||||
<xsl:value-of select="$sym-name" />
|
||||
<xsl:text>' (does the symbol support `@</xsl:text>
|
||||
<xsl:value-of select="$value" />
|
||||
<xsl:text>' and has it been imported?)</xsl:text>
|
||||
</xsl:message>
|
||||
<!-- error out only if lookup failures aren't explicitly suppressed -->
|
||||
<xsl:if test="not( @ignore-missing = 'true' )">
|
||||
<xsl:message>
|
||||
<xsl:text>warning: unable to find `@</xsl:text>
|
||||
<xsl:value-of select="$value" />
|
||||
<xsl:text>' for symbol `</xsl:text>
|
||||
<xsl:value-of select="$sym-name" />
|
||||
<xsl:text>' (does the symbol support `@</xsl:text>
|
||||
<xsl:value-of select="$value" />
|
||||
<xsl:text>' and has it been imported?)</xsl:text>
|
||||
</xsl:message>
|
||||
|
||||
<!-- just use the name if nothing is available -->
|
||||
<xsl:value-of select="$name" />
|
||||
<!-- just use the name if nothing is available -->
|
||||
<xsl:value-of select="$name" />
|
||||
</xsl:if>
|
||||
</xsl:when>
|
||||
|
||||
<xsl:otherwise>
|
||||
|
|
Loading…
Reference in New Issue