Hi,  
The problem of Compile hitting classes that aren't Serializable is one that I've found it very difficult to crack. I did quite a bit of work to get this right in the Saxon 8.4 release; the only way I know how to do it is to compile lots of stylesheets and make sure that they work. I've looked around for tools that inspect the code to check that all reachable classes are Serializable - one would think it's a simple enough problem - but can't find anything.  
 
 
 
I'm currently developing a tool for the static analysis of Java code using XQuery (and Saxon to run the queries...) and used it to check the Saxon 8.4 code base for issues related to "serializability". Based on a simple static type analysis the generated report lists all fields of all serializable classes which are not serializable . Hence, the report might contain false warnings with respect to the Saxon code base itself, e.g., a field with type "java.util.List" will be reported even if at runtime the referenced object is always serializable.
 
In short this report is far from being perfect but it maybe a start. I hope you find the report usefull. If you have any questions or further ideas what you always wanted to check just write me an email.
 
Furhter information about the tool can be found here: http://www.st.informatik.tu-darmstadt.de/static/pages/projects/Magellan/Magellan.html?View.ReplaceNavigation=/pages/projects/Magellan/links.html.
 
Unfortunately, a download is not available at the moment.
 
 
Here is the report:
 
<?xml version="1.0" encoding="UTF-8"?>
<report analysis="serializability">
<warning class="net.sf.saxon.xpath.XPathFunctionLibrary" field="resolver"/>
<warning class="net.sf.saxon.xpath.XPathFunctionCall" field="function"/>
<warning class="net.sf.saxon.value.StringValue" field="value"/>
<warning class="net.sf.saxon.value.SingletonNode" field="node"/>
<warning class="net.sf.saxon.value.SequenceType" field="primaryType"/>
<warning class="net.sf.saxon.value.SequenceType" field="pool"/>
<warning class="net.sf.saxon.value.SequenceIntent" field="iterator"/>
<warning class="net.sf.saxon.value.SequenceExtent" field="value"/>
<warning class="net.sf.saxon.value.SequenceExtent" field="itemType"/>
<warning class="net.sf.saxon.value.ObjectValue" field="value"/>
<warning class="net.sf.saxon.value.MemoClosure" field="reservoir"/>
<warning class="net.sf.saxon.value.IntegerValue" field="type"/>
<warning class="net.sf.saxon.value.Closure" field="expression"/>
<warning class="net.sf.saxon.value.Closure" field="savedXPathContext"/>
<warning class="net.sf.saxon.value.Closure" field="inputIterator"/>
<warning class="net.sf.saxon.value.BigIntegerValue" field="type"/>
<warning class="net.sf.saxon.type.Type" field="NODE_TYPE"/>
<warning class="net.sf.saxon.type.Type" field="ITEM_TYPE"/>
<warning class="net.sf.saxon.type.BuiltInAtomicType" field="dummyConversionContext"/>
<warning class="net.sf.saxon.trans.Mode$Rule" field="object"/>
<warning class="net.sf.saxon.trans.KeyDefinition" field="collation"/>
<warning class="net.sf.saxon.trans.IndependentContext" field="schemaImporter"/>
<warning class="net.sf.saxon.trans.IndependentContext" field="externalResolver"/>
<warning class="net.sf.saxon.trans.DynamicError" field="context"/>
<warning class="net.sf.saxon.style.StylesheetFunctionLibrary" field="stylesheet"/>
<warning class="net.sf.saxon.sort.UppercaseFirstComparer" field="baseCollator"/>
<warning class="net.sf.saxon.sort.TupleSorter" field="base"/>
<warning class="net.sf.saxon.sort.TupleExpression" field="components"/>
<warning class="net.sf.saxon.sort.TextComparer" field="collator"/>
<warning class="net.sf.saxon.sort.SortKeyDefinition" field="sortKey"/>
<warning class="net.sf.saxon.sort.SortKeyDefinition" field="order"/>
<warning class="net.sf.saxon.sort.SortKeyDefinition" field="dataTypeExpression"/>
<warning class="net.sf.saxon.sort.SortKeyDefinition" field="caseOrder"/>
<warning class="net.sf.saxon.sort.SortKeyDefinition" field="language"/>
<warning class="net.sf.saxon.sort.SortKeyDefinition" field="collationName"/>
<warning class="net.sf.saxon.sort.SortKeyDefinition" field="collation"/>
<warning class="net.sf.saxon.sort.SortExpression" field="select"/>
<warning class="net.sf.saxon.sort.LowercaseFirstComparer" field="baseCollator"/>
<warning class="net.sf.saxon.sort.DocumentSorter" field="comparer"/>
<warning class="net.sf.saxon.sort.DescendingComparer" field="baseComparer"/>
<warning class="net.sf.saxon.sort.AtomicSortComparer" field="collator"/>
<warning class="net.sf.saxon.sort.AtomicSortComparer" field="conversion"/>
<warning class="net.sf.saxon.sort.AtomicComparer" field="collator"/>
<warning class="net.sf.saxon.sort.AtomicComparer" field="conversion"/>
<warning class="net.sf.saxon.query.XQueryFunctionLibrary" field="unboundFunctionCalls"/>
<warning class="net.sf.saxon.pattern.SubstitutionGroupTest" field="group"/>
<warning class="net.sf.saxon.pattern.LocationPathPattern" field="filters"/>
<warning class="net.sf.saxon.pattern.LocationPathPattern" field="equivalentExpr"/>
<warning class="net.sf.saxon.pattern.KeyPattern" field="keyexp"/>
<warning class="net.sf.saxon.pattern.IDPattern" field="idExpression"/>
<warning class="net.sf.saxon.pattern.ContentTypeTest" field="schemaType"/>

<warning class="net.sf.saxon.instruct.While" field="test"/>

<warning class="net.sf.saxon.instruct.While" field="action"/>

<warning class="net.sf.saxon.instruct.TraceWrapper" field="child"/>

<warning class="net.sf.saxon.instruct.TraceInstruction" field="details"/>

<warning class="net.sf.saxon.instruct.TraceExpression" field="namespaceResolver"/>

<warning class="net.sf.saxon.instruct.SimpleNodeConstructor" field="select"/>

<warning class="net.sf.saxon.instruct.SimpleContentConstructor" field="select"/>

<warning class="net.sf.saxon.instruct.SimpleContentConstructor" field="separator"/>

<warning class="net.sf.saxon.instruct.ResultDocument" field="href"/>

<warning class="net.sf.saxon.instruct.ResultDocument" field="content"/>

<warning class="net.sf.saxon.instruct.ResultDocument" field="schemaType"/>

<warning class="net.sf.saxon.instruct.ResultDocument" field="nsResolver"/>

<warning class="net.sf.saxon.instruct.ProcessingInstruction" field="name"/>

<warning class="net.sf.saxon.instruct.Procedure" field="body"/>

<warning class="net.sf.saxon.instruct.ParentNodeConstructor" field="content"/>

<warning class="net.sf.saxon.instruct.ParentNodeConstructor" field="schemaType"/>

<warning class="net.sf.saxon.instruct.NumberInstruction" field="select"/>

<warning class="net.sf.saxon.instruct.NumberInstruction" field="value"/> 

 <warning class="net.sf.saxon.instruct.NumberInstruction" field="format"/>

<warning class="net.sf.saxon.instruct.NumberInstruction" field="groupSize"/>

<warning class="net.sf.saxon.instruct.NumberInstruction" field="groupSeparator"/>

<warning class="net.sf.saxon.instruct.NumberInstruction" field="letterValue"/>

<warning class="net.sf.saxon.instruct.NumberInstruction" field="ordinal"/>

<warning class="net.sf.saxon.instruct.NumberInstruction" field="lang"/>

<warning class="net.sf.saxon.instruct.NumberInstruction" field="numberer"/>

<warning class="net.sf.saxon.instruct.NumberInstruction" field="defaultNumberer"/>

<warning class="net.sf.saxon.instruct.Namespace" field="name"/>

<warning class="net.sf.saxon.instruct.Message" field="terminate"/>

<warning class="net.sf.saxon.instruct.Message" field="select"/>

<warning class="net.sf.saxon.instruct.LocalParam" field="conversion"/>

<warning class="net.sf.saxon.instruct.InstructionDetails" field="namespaceResolver"/>

<warning class="net.sf.saxon.instruct.GeneralVariable" field="select"/>

<warning class="net.sf.saxon.instruct.ForEachGroup" field="select"/>

<warning class="net.sf.saxon.instruct.ForEachGroup" field="action"/>

<warning class="net.sf.saxon.instruct.ForEachGroup" field="key"/>

<warning class="net.sf.saxon.instruct.ForEachGroup" field="collator"/>

<warning class="net.sf.saxon.instruct.ForEach" field="select"/>

<warning class="net.sf.saxon.instruct.ForEach" field="action"/>

<warning class="net.sf.saxon.instruct.FixedElement" field="itemType"/>

<warning class="net.sf.saxon.instruct.FixedAttribute" field="schemaType"/>

<warning class="net.sf.saxon.instruct.Doctype" field="content"/>

<warning class="net.sf.saxon.instruct.CopyOf" field="select"/>

<warning class="net.sf.saxon.instruct.CopyOf" field="schemaType"/>

<warning class="net.sf.saxon.instruct.Copy" field="contextItemType"/>

<warning class="net.sf.saxon.instruct.ComputedElement" field="elementName"/>

<warning class="net.sf.saxon.instruct.ComputedElement" field="namespace"/>

<warning class="net.sf.saxon.instruct.ComputedElement" field="nsContext"/>

<warning class="net.sf.saxon.instruct.ComputedElement" field="itemType"/>

<warning class="net.sf.saxon.instruct.Choose" field="conditions"/>

<warning class="net.sf.saxon.instruct.Choose" field="actions"/>

<warning class="net.sf.saxon.instruct.CallTemplate" field="calledTemplateExpression"/>

<warning class="net.sf.saxon.instruct.CallTemplate" field="nsContext"/>

<warning class="net.sf.saxon.instruct.Block" field="children"/>

<warning class="net.sf.saxon.instruct.Attribute" field="attributeName"/>

<warning class="net.sf.saxon.instruct.Attribute" field="namespace"/>

<warning class="net.sf.saxon.instruct.Attribute" field="nsContext"/>

<warning class="net.sf.saxon.instruct.Attribute" field="schemaType"/>

<warning class="net.sf.saxon.instruct.Assign" field="binding"/>

<warning class="net.sf.saxon.instruct.ApplyTemplates" field="select"/>

<warning class="net.sf.saxon.instruct.AnalyzeString" field="select"/>

<warning class="net.sf.saxon.instruct.AnalyzeString" field="regex"/>

<warning class="net.sf.saxon.instruct.AnalyzeString" field="flags"/>

<warning class="net.sf.saxon.instruct.AnalyzeString" field="matching"/>

<warning class="net.sf.saxon.instruct.AnalyzeString" field="nonMatching"/>

<warning class="net.sf.saxon.functions.Trace" field="resolver"/>

<warning class="net.sf.saxon.functions.SystemProperty" field="nsContext"/>

<warning class="net.sf.saxon.functions.StandardFunction$Entry" field="itemType"/>

<warning class="net.sf.saxon.functions.Key" field="nsContext"/>

<warning class="net.sf.saxon.functions.JavaExtensionLibrary$UnresolvedExtensionFunction" field="candidateMethods"/>

<warning class="net.sf.saxon.functions.FunctionLibraryList" field="libraryList"/>

<warning class="net.sf.saxon.functions.FormatNumber2" field="nsContext"/>

<warning class="net.sf.saxon.functions.FormatNumber" field="nsContext"/>

<warning class="net.sf.saxon.functions.CollatingFunction" field="collation"/>

<warning class="net.sf.saxon.expr.VariableReference" field="binding"/>

<warning class="net.sf.saxon.expr.UserFunctionCall$FunctionCallPackage" field="actualArgs"/>

<warning class="net.sf.saxon.expr.UserFunctionCall$FunctionCallPackage" field="evaluationContext"/>

<warning class="net.sf.saxon.expr.UntypedAtomicConverter" field="requiredItemType"/>

<warning class="net.sf.saxon.expr.UnaryExpression" field="operand"/>

<warning class="net.sf.saxon.expr.TailExpression" field="base"/>

<warning class="net.sf.saxon.expr.SimpleMappingExpression" field="start"/>

<warning class="net.sf.saxon.expr.SimpleMappingExpression" field="step"/>

<warning class="net.sf.saxon.expr.SimpleExpression" field="NO_ARGUMENTS"/>

<warning class="net.sf.saxon.expr.SimpleExpression" field="arguments"/>

<warning class="net.sf.saxon.expr.RoleLocator" field="container"/>

<warning class="net.sf.saxon.expr.RoleLocator" field="sourceLocator"/>

<warning class="net.sf.saxon.expr.PathExpression" field="start"/>

<warning class="net.sf.saxon.expr.PathExpression" field="step"/>

<warning class="net.sf.saxon.expr.ItemChecker" field="requiredItemType"/>

<warning class="net.sf.saxon.expr.IntegerRangeTest" field="value"/>

<warning class="net.sf.saxon.expr.IntegerRangeTest" field="min"/>

<warning class="net.sf.saxon.expr.IntegerRangeTest" field="max"/>

<warning class="net.sf.saxon.expr.InstanceOfExpression" field="targetType"/>

<warning class="net.sf.saxon.expr.IfExpression" field="condition"/>

<warning class="net.sf.saxon.expr.IfExpression" field="thenExp"/>

<warning class="net.sf.saxon.expr.IfExpression" field="elseExp"/>

<warning class="net.sf.saxon.expr.FunctionCall" field="argument"/>

<warning class="net.sf.saxon.expr.ForExpression" field="positionBinding"/>

<warning class="net.sf.saxon.expr.FilterExpression" field="start"/>

<warning class="net.sf.saxon.expr.FilterExpression" field="filter"/>

<warning class="net.sf.saxon.expr.ContextItemExpression" field="itemType"/>

<warning class="net.sf.saxon.expr.ComputedExpression" field="parentExpression"/>

<warning class="net.sf.saxon.expr.CastableExpression" field="targetType"/>

<warning class="net.sf.saxon.expr.CastExpression" field="targetType"/>

<warning class="net.sf.saxon.expr.CastExpression" field="targetPrimitiveType"/>

<warning class="net.sf.saxon.expr.CastAsQName" field="operand"/>

<warning class="net.sf.saxon.expr.CastAsQName" field="targetType"/>

<warning class="net.sf.saxon.expr.BinaryExpression" field="operand0"/>

<warning class="net.sf.saxon.expr.BinaryExpression" field="operand1"/>

<warning class="net.sf.saxon.expr.AxisExpression" field="itemType"/>

<warning class="net.sf.saxon.expr.AtomicSequenceConverter" field="reqItemType"/>

<warning class="net.sf.saxon.expr.Assignation" field="sequence"/>

<warning class="net.sf.saxon.expr.Assignation" field="action"/>

<warning class="net.sf.saxon.expr.ArithmeticExpression" field="plusTable"/>

<warning class="net.sf.saxon.expr.ArithmeticExpression" field="minusTable"/>

<warning class="net.sf.saxon.expr.ArithmeticExpression" field="multiplyTable"/>

<warning class="net.sf.saxon.expr.ArithmeticExpression" field="divideTable"/>

<warning class="net.sf.saxon.expr.ArithmeticExpression" field="idivTable"/>

<warning class="net.sf.saxon.expr.ArithmeticExpression" field="modTable"/>

<warning class="net.sf.saxon.Configuration" field="traceListener"/>

<warning class="net.sf.saxon.Configuration" field="debugger"/>

<warning class="net.sf.saxon.Configuration" field="externalObjectModels"/>

<warning class="net.sf.saxon.Configuration" field="classLoader"/> 

 </report>

 
 
 
Best regards,
Michael Eichberg