> I've recently proposed a family of random number functions for XPath 3.1,
> and I included permute() as a primitive on the theory that a native
> implementation might be considerably more efficient than a user-written
> implementation.
>
Which, for those that have interest in following it, can be found here, and
was apparently originally reported/requested by Jakub Maly, with Michael's
proposal in comment #4: https://www.w3.org/Bugs/Public/show_bug.cgi?id=20573
As the (publicly viewable) comment #4 states, the proposal was added to the
internal Draft of XPath 3.1. Not much help to you yet, I think, because I
highly doubt that there is already an implementation available that supports
this.
As an aside, you may be interested in using FXSL for random numbers, which has
function (or named template) for this purpose. See for examples:
http://fxsl.sourceforge.net/articles/Random/Casting%20the%20Dice%20with%20FXS
L-htm.htm
Cheers,
Abel
|