> On Aug 3, 2018, at 15:36, Alexis King wrote:
>
> Maybe this isn’t really a direct response to the direction this thread
> has taken, but given the question proposed in the original message, I
> think it’s relevant to share a particular design pattern for parameters
> that seems to work well.
Why didn't [racket-users] tag get added to John Clements' message
``Parameters considered often harmful''. Was it because the tag was
already contained in the subject? Is that how Google Groups avoids
always adding the tag forever?
I wonder why they don't use message headers to know whether it's
Hello everyone,
Thanks for all the responses, they have been very clarifying.
I'd like to add the following for your consideration of using parameters.
When using the plot package, I really like to setup common parameters using
parameterize and then tweak others using the named parameters in th
Maybe this isn’t really a direct response to the direction this thread
has taken, but given the question proposed in the original message, I
think it’s relevant to share a particular design pattern for parameters
that seems to work well. In a number of different APIs provided by
Racket, a function’
On Friday, August 3, 2018 at 1:24:08 AM UTC+8, johnbclements wrote:
>
> I hate to turn a little question into a big one, but… are parameters the
> right choice, here? It seems to me that optional parameters would be more
> suitable.
>
Most (but not all) parameters act as default values for re
On Friday, August 3, 2018 at 6:22:10 AM UTC+8, Alex Harsanyi wrote:
>
>
>
> On Thursday, August 2, 2018 at 11:19:58 PM UTC+8, Carlos Lopez wrote:
>>
>> Thanks Alex!
>>
>> Right, so make-bm is being called from another thread and so the
>> parameters are different there.
>>
>
> The parameters sho
On Thursday, August 2, 2018 at 11:19:58 PM UTC+8, Carlos Lopez wrote:
>
> Thanks Alex!
>
> Right, so make-bm is being called from another thread and so the
> parameters are different there.
>
The parameters should not be different. The objective of the save/restore
parameters is to make sure
I hate to turn a little question into a big one, but… are parameters the right
choice, here? It seems to me that optional parameters would be more suitable.
Unfortunately, I’ve been on the other side of this fence, too: parameters are
vastly more convenient for implementors than adding optional
Thanks Alex!
Right, so make-bm is being called from another thread and so the parameters
are different there.
That explains why in this case, the axes are hidden:
#lang racket
(require plot)
(plot-new-window? #t)
(plot-decorations? #f)
(parameterize ()
(plot3d (surface3d (λ (x y) (* (cos x)
Parameters don't keep their values across threads, and since the plot
library needs to re-draw the plot when it is rotated or zoomed, it saves
parameters for later use in a different thread, where the drawing actually
happpens. There is an explicit list of parameters that are saved and
restore
10 matches
Mail list logo