Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(275)

Side by Side Diff: third_party/libxslt/libexslt/saxon.c

Issue 1193533007: Upgrade to libxml 2.9.2 and libxslt 1.1.28 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: no iconv Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « third_party/libxslt/libexslt/math.c ('k') | third_party/libxslt/libexslt/strings.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #define IN_LIBEXSLT 1 #define IN_LIBEXSLT
2 #include "libexslt/libexslt.h" 2 #include "libexslt/libexslt.h"
3 3
4 #if defined(WIN32) && !defined (__CYGWIN__) && (!__MINGW32__) 4 #if defined(WIN32) && !defined (__CYGWIN__) && (!__MINGW32__)
5 #include <win32config.h> 5 #include <win32config.h>
6 #else 6 #else
7 #include "config.h" 7 #include "config.h"
8 #endif 8 #endif
9 9
10 #include <libxml/tree.h> 10 #include <libxml/tree.h>
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after
173 if (nargs != 1) { 173 if (nargs != 1) {
174 xmlXPathSetArityError(ctxt); 174 xmlXPathSetArityError(ctxt);
175 return; 175 return;
176 } 176 }
177 177
178 exsltSaxonExpressionFunction(ctxt, 1); 178 exsltSaxonExpressionFunction(ctxt, 1);
179 exsltSaxonEvalFunction(ctxt, 1); 179 exsltSaxonEvalFunction(ctxt, 1);
180 } 180 }
181 181
182 /** 182 /**
183 * exsltSaxonSystemIdFunction:
184 * @ctxt: an XPath parser context
185 * @nargs: number of arguments
186 *
187 * Implements the SAXON systemId() function
188 * string saxon:systemId ()
189 * This function returns the system ID of the document being styled.
190 */
191 static void
192 exsltSaxonSystemIdFunction(xmlXPathParserContextPtr ctxt, int nargs)
193 {
194 if (ctxt == NULL)
195 return;
196 if (nargs != 0) {
197 xmlXPathSetArityError(ctxt);
198 return;
199 }
200
201 if ((ctxt->context) && (ctxt->context->doc) &&
202 (ctxt->context->doc->URL))
203 valuePush(ctxt, xmlXPathNewString(ctxt->context->doc->URL));
204 else
205 valuePush(ctxt, xmlXPathNewString(BAD_CAST ""));
206 }
207
208 /**
183 * exsltSaxonLineNumberFunction: 209 * exsltSaxonLineNumberFunction:
184 * @ctxt: an XPath parser context 210 * @ctxt: an XPath parser context
185 * @nargs: number of arguments 211 * @nargs: number of arguments
186 * 212 *
187 * Implements the SAXON line-number() function 213 * Implements the SAXON line-number() function
188 * integer saxon:line-number() 214 * integer saxon:line-number()
189 * 215 *
190 * This returns the line number of the context node in the source document 216 * This returns the line number of the context node in the source document
191 * within the entity that contains it. There are no arguments. If line numbers 217 * within the entity that contains it. There are no arguments. If line numbers
192 * are not maintained for the current document, the function returns -1. (To 218 * are not maintained for the current document, the function returns -1. (To
193 * ensure that line numbers are maintained, use the -l option on the command 219 * ensure that line numbers are maintained, use the -l option on the command
194 * line) 220 * line)
195 * 221 *
196 * The extension has been extended to have the following form: 222 * The extension has been extended to have the following form:
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
257 exsltSaxonExpressionFunction); 283 exsltSaxonExpressionFunction);
258 xsltRegisterExtModuleFunction((const xmlChar *) "eval", 284 xsltRegisterExtModuleFunction((const xmlChar *) "eval",
259 SAXON_NAMESPACE, 285 SAXON_NAMESPACE,
260 exsltSaxonEvalFunction); 286 exsltSaxonEvalFunction);
261 xsltRegisterExtModuleFunction((const xmlChar *) "evaluate", 287 xsltRegisterExtModuleFunction((const xmlChar *) "evaluate",
262 SAXON_NAMESPACE, 288 SAXON_NAMESPACE,
263 exsltSaxonEvaluateFunction); 289 exsltSaxonEvaluateFunction);
264 xsltRegisterExtModuleFunction ((const xmlChar *) "line-number", 290 xsltRegisterExtModuleFunction ((const xmlChar *) "line-number",
265 SAXON_NAMESPACE, 291 SAXON_NAMESPACE,
266 exsltSaxonLineNumberFunction); 292 exsltSaxonLineNumberFunction);
293 xsltRegisterExtModuleFunction ((const xmlChar *) "systemId",
294 SAXON_NAMESPACE,
295 exsltSaxonSystemIdFunction);
267 } 296 }
OLDNEW
« no previous file with comments | « third_party/libxslt/libexslt/math.c ('k') | third_party/libxslt/libexslt/strings.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698