RE: [racket-users] Calling a procedure without allowing it to permanently alter parameters.

2016-01-13 Thread Jos Koot
Jon and Jon, Both thanks for your replies. I'll stick to call-in-nested-thread. Jos _ From: Jon Zeppieri [mailto:zeppi...@gmail.com] Sent: miƩrcoles, 13 de enero de 2016 6:03 To: Jos Koot Cc: Racket Users Subject: Re: [racket-users] Calling a procedure without allowing it to permanently

Re: [racket-users] Calling a procedure without allowing it to permanently alter parameters.

2016-01-12 Thread Jon Zeppieri
I don't think there is a better way than what you have. I looked into the undocumented `reparameterize` procedure, from '#%paramz: [ https://github.com/racket/racket/blob/a6eb00a41cc29859424335f40ef9ae68c471c57a/racket/src/racket/src/thread.c#L7680], but it only copies built-in parameters, so it

Re: [racket-users] Calling a procedure without allowing it to permanently alter parameters.

2016-01-12 Thread jon stenerson
a procedure without allowing it to permanently alter parameters. Can you use this instead? (define (protected-caller thunk) (parameterize ([p 'anything]) (thunk))) Works for me Jon -- You received this message because you are subscribed to the Google Groups "Racket Users&q

RE: [racket-users] Calling a procedure without allowing it to permanently alter parameters.

2016-01-12 Thread Jos Koot
[mailto:racket-users@googlegroups.com] On Behalf Of jon stenerson Sent: miƩrcoles, 13 de enero de 2016 0:50 To: racket-users@googlegroups.com Subject: Re: [racket-users] Calling a procedure without allowing it to permanently alter parameters. Can you use this instead? (define (protected-caller thunk

Re: [racket-users] Calling a procedure without allowing it to permanently alter parameters.

2016-01-12 Thread jon stenerson
Can you use this instead? (define (protected-caller thunk) (parameterize ([p 'anything]) (thunk))) Works for me Jon -- You received this message because you are subscribed to the Google Groups "Racket Users" group. To unsubscribe from this group and stop receiving emails from it, send