mirror of
				https://gitlab.gnome.org/GNOME/libxslt
				synced 2025-11-04 00:53:12 +03:00 
			
		
		
		
	fixes bug #97969 for @*[...] patterns added the example in the regression
* libxslt/pattern.c: fixes bug #97969 for @*[...] patterns * tests/docs/Makefile.am tests/docs/bug-97.xml tests/general/Makefile.am tests/general/bug-97.*: added the example in the regression tests for this case Daniel
This commit is contained in:
		@@ -1,3 +1,10 @@
 | 
				
			|||||||
 | 
					Wed Nov 13 10:35:46 CET 2002 Daniel Veillard <daniel@veillard.com>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						* libxslt/pattern.c: fixes bug #97969 for @*[...] patterns
 | 
				
			||||||
 | 
						* tests/docs/Makefile.am tests/docs/bug-97.xml
 | 
				
			||||||
 | 
						  tests/general/Makefile.am tests/general/bug-97.*: added the
 | 
				
			||||||
 | 
						  example in the regression tests for this case
 | 
				
			||||||
 | 
						
 | 
				
			||||||
Tue Nov 12 22:35:47 CET 2002 Daniel Veillard <daniel@veillard.com>
 | 
					Tue Nov 12 22:35:47 CET 2002 Daniel Veillard <daniel@veillard.com>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	* libxslt/transform.c: fixes bug #97950 for cdata-section-elements
 | 
						* libxslt/transform.c: fixes bug #97950 for cdata-section-elements
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1342,7 +1342,7 @@ xsltCompileStepPattern(xsltParserContextPtr ctxt, xmlChar *token) {
 | 
				
			|||||||
	if (CUR == '*') {
 | 
						if (CUR == '*') {
 | 
				
			||||||
	    NEXT;
 | 
						    NEXT;
 | 
				
			||||||
	    PUSH(XSLT_OP_ATTR, NULL, NULL);
 | 
						    PUSH(XSLT_OP_ATTR, NULL, NULL);
 | 
				
			||||||
	    return;
 | 
						    goto parse_predicate;
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
	token = xsltScanQName(ctxt, &prefix);
 | 
						token = xsltScanQName(ctxt, &prefix);
 | 
				
			||||||
	if (prefix != NULL) {
 | 
						if (prefix != NULL) {
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -96,6 +96,7 @@ EXTRA_DIST =	\
 | 
				
			|||||||
	bug-94.xml \
 | 
						bug-94.xml \
 | 
				
			||||||
	bug-95.xml \
 | 
						bug-95.xml \
 | 
				
			||||||
	bug-96.xml \
 | 
						bug-96.xml \
 | 
				
			||||||
 | 
						bug-97.xml \
 | 
				
			||||||
	character.xml \
 | 
						character.xml \
 | 
				
			||||||
	array.xml \
 | 
						array.xml \
 | 
				
			||||||
	items.xml
 | 
						items.xml
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										16
									
								
								tests/docs/bug-97.xml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										16
									
								
								tests/docs/bug-97.xml
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,16 @@
 | 
				
			|||||||
 | 
					<?xml version="1.0" encoding="UTF-8"?>
 | 
				
			||||||
 | 
					<car:cars xmlns:car="http://www.example.com/xmlns/car"
 | 
				
			||||||
 | 
					          xmlns:m="http://www.example.com/xmlns/manufacturer">
 | 
				
			||||||
 | 
					  <car:models>
 | 
				
			||||||
 | 
					    <car:model car:name="Rabbit" m:id="VW" car:year="1984" />
 | 
				
			||||||
 | 
					    <car:model car:name="Tundra" m:id="TY" car:year="2000" />
 | 
				
			||||||
 | 
					    <car:model car:name="Mini" m:id="BM" car:year="2003" />
 | 
				
			||||||
 | 
					  </car:models>
 | 
				
			||||||
 | 
					  <m:manufacturers>
 | 
				
			||||||
 | 
					    <m:manufacturer m:id="VW" m:name="Volkswagen" m:country="Germany" />
 | 
				
			||||||
 | 
					    <m:manufacturer m:id="TY" m:name="Toyota" m:country="Japan" />
 | 
				
			||||||
 | 
					    <m:manufacturer m:id="BM" m:name="Bavarian Motor Works" 
 | 
				
			||||||
 | 
					m:country="Germany"/>
 | 
				
			||||||
 | 
					  </m:manufacturers>
 | 
				
			||||||
 | 
					</car:cars>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -100,6 +100,7 @@ EXTRA_DIST = \
 | 
				
			|||||||
    bug-94.out bug-94.xsl \
 | 
					    bug-94.out bug-94.xsl \
 | 
				
			||||||
    bug-95.out bug-95.xsl \
 | 
					    bug-95.out bug-95.xsl \
 | 
				
			||||||
    bug-96.out bug-96.xsl \
 | 
					    bug-96.out bug-96.xsl \
 | 
				
			||||||
 | 
					    bug-97.out bug-97.xsl \
 | 
				
			||||||
    character.out character.xsl \
 | 
					    character.out character.xsl \
 | 
				
			||||||
    character2.out character2.xsl \
 | 
					    character2.out character2.xsl \
 | 
				
			||||||
    itemschoose.out itemschoose.xsl \
 | 
					    itemschoose.out itemschoose.xsl \
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										9
									
								
								tests/general/bug-97.out
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								tests/general/bug-97.out
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,9 @@
 | 
				
			|||||||
 | 
					My Car Models:
 | 
				
			||||||
 | 
					Rabbit
 | 
				
			||||||
 | 
					Tundra
 | 
				
			||||||
 | 
					Mini
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					The Manufacturers:
 | 
				
			||||||
 | 
					Volkswagen
 | 
				
			||||||
 | 
					Toyota
 | 
				
			||||||
 | 
					Bavarian Motor Works
 | 
				
			||||||
							
								
								
									
										32
									
								
								tests/general/bug-97.xsl
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										32
									
								
								tests/general/bug-97.xsl
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,32 @@
 | 
				
			|||||||
 | 
					<?xml version="1.0" encoding="UTF-8"?>
 | 
				
			||||||
 | 
					<xsl:stylesheet version="1.0"
 | 
				
			||||||
 | 
					  xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
 | 
				
			||||||
 | 
					  xmlns:car="http://www.example.com/xmlns/car"
 | 
				
			||||||
 | 
					  xmlns:manu="http://www.example.com/xmlns/manufacturer">
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  <xsl:output method="text" encoding="UTF-8" />
 | 
				
			||||||
 | 
					  <xsl:strip-space elements="*" />
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  <xsl:template match="/">
 | 
				
			||||||
 | 
					    <xsl:apply-templates />
 | 
				
			||||||
 | 
					  </xsl:template>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  <xsl:template match="car:models">
 | 
				
			||||||
 | 
					    <xsl:text>My Car Models:
</xsl:text>
 | 
				
			||||||
 | 
					    <xsl:apply-templates select="car:model/@car:name"></xsl:apply-templates>
 | 
				
			||||||
 | 
					    <xsl:text>
</xsl:text>
 | 
				
			||||||
 | 
					  </xsl:template>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  <xsl:template match="manu:manufacturers">
 | 
				
			||||||
 | 
					    <xsl:text>The Manufacturers:
</xsl:text>
 | 
				
			||||||
 | 
					    <xsl:apply-templates select="manu:manufacturer/@manu:name"></xsl:apply-templates>
 | 
				
			||||||
 | 
					  </xsl:template>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  <xsl:template match="@*[local-name()='name']">
 | 
				
			||||||
 | 
					    <xsl:value-of select="." />
 | 
				
			||||||
 | 
					    <xsl:text>
</xsl:text>
 | 
				
			||||||
 | 
					  </xsl:template>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					</xsl:stylesheet>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
		Reference in New Issue
	
	Block a user