#293 template entry/exit isn't traced

v8.2
closed
Michael Kay
5
2012-10-08
2005-01-20
Michael Kay
No

Trace output using the -T option doesn't include
tracing of the entry and exit to XSLT templates. Also,
these events are not notified to a user-defined trace
listener.

Source fix: at line 290 of
net.sf.saxon.style.XSLTemplate, add the line

        compiledTemplate.setBody(exp);

so that the code reads:

    if (getConfiguration().getTraceListener() !=

null) {
TraceWrapper trace = new
TraceInstruction(exp, this);

trace.setLocationId(allocateLocationId(getSystemId(),
getLineNumber()));
trace.setParentExpression(compiledTemplate);
exp = trace;
compiledTemplate.setBody(exp);
}

Michael Kay

Discussion