PLEASE DO NOT REPLY TO THIS MESSAGE. TO FURTHER COMMENT ON THE STATUS OF THIS BUG PLEASE FOLLOW THE LINK BELOW AND USE THE ON-LINE APPLICATION. REPLYING TO THIS MESSAGE DOES NOT UPDATE THE DATABASE, AND SO YOUR COMMENT WILL BE LOST SOMEWHERE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=3238 *** shadow/3238 Wed Aug 22 16:39:25 2001 --- shadow/3238.tmp.29455 Thu Aug 23 16:38:46 2001 *************** *** 1,5 **** +============================================================================+ ! | incorrect results for predicates applied to parameters in the select of a | +----------------------------------------------------------------------------+ | Bug #: 3238 Product: XalanJ2 | | Status: NEW Version: CurrentCVS | --- 1,5 ---- +============================================================================+ ! | for-each, xpath-iterators and template parameters (oh my!) | +----------------------------------------------------------------------------+ | Bug #: 3238 Product: XalanJ2 | | Status: NEW Version: CurrentCVS | *************** *** 102,105 **** 102030 ------- Additional Comments From [EMAIL PROTECTED] 2001-08-22 16:39 ------- ! Possibly related to http://nagoya.apache.org/bugzilla/show_bug.cgi?id=1532 --- 102,131 ---- 102030 ------- Additional Comments From [EMAIL PROTECTED] 2001-08-22 16:39 ------- ! Possibly related to http://nagoya.apache.org/bugzilla/show_bug.cgi?id=1532 ! ! ------- Additional Comments From [EMAIL PROTECTED] 2001-08-23 16:38 ------- ! I now think this bug has more in common with ! http://nagoya.apache.org/bugzilla/show_bug.cgi?id=2468 ! ! It appears to me that bug #2468 is indicative of a category of problems with ! the runtime (that of how xpath iterators are reset). I am guessing that the ! (compiler) patch applied to #2468 is enough for that particular case but ! insufficient for the category. ! ! I'm suspecting that the problems stem from (most) iterators that implement ! setStartNode(int) with different codepaths between clones and non-clones. ! Consider for-each::translate(): the loop's iterator is reset prior to the ! looptest but depending upon the cloneness of the iterator setStartNode(int) may ! reset the iterator incorrectly (the committed patch for #2468 determines if a ! call to setStartNode(int) should be generated by checking the type of the for- ! each argument - in that case, if the argument is of ReferenceType). Of course ! this patch addresses only those cases where the argument can be inferred at ! compiletime to be a clone (as in the case of a ReferenceType). For the current ! bug, the argument is of NodeSetType and provides no helpful information on how ! to reset it. It would appear that more runtime work is needed - perhaps more ! iterator state/context information is needed. ! ! As an aside, can anyone explain why (most) clones of iterators aren't ! restartable? Isn't a clone of an iterator a deep copy of the iterator's context? !
