[racket-dev] [plt] Push #25698: master branch updated

From: Ryan Culpepper (ryan at cs.utah.edu)
Date: Fri Nov 16 17:31:45 EST 2012

On 11/16/2012 04:43 PM, Neil Toronto wrote:
> On 11/16/2012 02:10 PM, mflatt at racket-lang.org wrote:
>> 9a48e5d Matthew Flatt<mflatt at racket-lang.org>  2012-11-16 14:03
>> :
>> | math: avoid import at unnecessary phase
>> |
>> | This repair avoids using at compile time external libraries that
>> | are needed at run time.
>> :
>>    M collects/math/private/matrix/matrix-sequences.rkt | 4 +---
>  >
>  > [...]
>  >
>> collects/math/private/matrix/matrix-sequences.rkt
>> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> --- OLD/collects/math/private/matrix/matrix-sequences.rkt
>> +++ NEW/collects/math/private/matrix/matrix-sequences.rkt
>> @@ -5,9 +5,7 @@
>>            in-column)
>>
>>   (require math/array
>> -         (except-in math/matrix in-row in-column)
>> -         (for-syntax (except-in math/matrix in-row in-column))
>> -         (for-template (except-in math/matrix in-row in-column)))
>> +         (except-in math/matrix in-row in-column))
>
> Was this the only necessary change? If so, it's a little weird, because
> libmpfr isn't supposed to be loaded until its first export is used. The
> constants are all delayed (their names are bound to macros that expand
> to uses of `force'), and every function and delay thunk is wrapped with
> code that loads the external library. IOW, this:
>
>    (require math/bigfloat)
>
> doesn't load libmpfr, but this does:
>
>    pi.bf
>
> Also, I have no idea what it all has to do with a typed submodule in
> "math/special-functions.rkt", which is apparently what the error was
> complaining about. I can't work out the dependency chain. Help?
>
> (FWIW, you're right about libmpfr not being needed at compile time.
> Well, it shouldn't be. I used Eli's nifty interaction-fakery code forms
> in the `math/bigfloat' docs, for example.)

If you made bigfloats serializable, you could also use 
'make-log-based-eval' from unstable/sandbox as an alternative to 
'eval:alts'.

Ryan


Posted on the dev mailing list.