[XeTeX] Random number primitives
David Carlisle
d.p.carlisle at gmail.com
Sun Nov 13 18:32:06 CET 2016
On 13 November 2016 at 16:47, Apostolos Syropoulos
<asyropoulos at yahoo.com> wrote:
>>
>> That's true except that as pdftex and luatex have this already and have had
>> for years, in this particular instance it's playing catchup that is
>> being suggested.
>> Not promoting novel functionality.
>>
>
> So just because the design in pdftex and luatex was conservative, if not flawed,
> it doesn't mean we should follow their "lead".
that is the model in much of xetex as far as features not relating to
unicode and font support are concerned:
that something that works in (pdf)tex and xetex should work the same
way in the two systems.
> The point here is to produce
> pseudo-random numbers. How they will be produced is something that the end user
> should not worry about.
It depends. currently, if you set the seed you get the same numbers
from luatex and pdftex.
if xetex uses a different RNG then you would get different numbers in
xetex. that complicates some
things not least testing cross platform compatibility.
> In addition, it would be a nice opportunity for pdftex
> and luatex to "upgrade".
Perhaps. But that wasn't the current request.
>
>
>>
>> Not really. If the main use cases are met by the existing code then engine
>> differences are just extra work for the maintainers of the macro format
>> to hide to provide a consistent interface to the end user.
>>
>
> This is a fallacy! Just becauce LaTeX can process UTF-8 encoded input files,
> it doesn't mean XeTeX is useless!
That isn't what I said.
> And there is no extra code.
Oh there would be _less_ code probably as you'd use a system call rather than
implement the function inline, that isn't the issue.
> It would be just
> a simple system call. So instead of implementing random with a call to
>
>
> long random(void)
>
>
> one should implement it with a call to
>
>
> long lrand48(void)
>
> A.S.
David
More information about the XeTeX
mailing list