Re: [racket-users] sharing a value between a DrRacket tool and a user program

2017-05-16 Thread Robby Findler
On Tue, May 16, 2017 at 7:07 PM, 'John Clements' via Racket Users wrote: > >> On May 16, 2017, at 11:26 AM, Robby Findler >> wrote: >> >> If you have control of the language<%> class, then you can do that via >> the on-execute method.

Re: [racket-users] sharing a value between a DrRacket tool and a user program

2017-05-16 Thread 'John Clements' via Racket Users
> On May 16, 2017, at 11:26 AM, Robby Findler > wrote: > > If you have control of the language<%> class, then you can do that via > the on-execute method. If you want to do that for all languages (which > is probably not a good idea, but you could use this approach

Re: [racket-users] sharing a value between a DrRacket tool and a user program

2017-05-16 Thread 'John Clements' via Racket Users
> On May 16, 2017, at 11:23 AM, Vincent St-Amour > wrote: > > John, Austin, > > You can use loggers for this. The `data` argument to `log-message` > allows payloads to be carried along with log messages. Just have the > user program log messages with a

Re: [racket-users] sharing a value between a DrRacket tool and a user program

2017-05-16 Thread Robby Findler
If you have control of the language<%> class, then you can do that via the on-execute method. If you want to do that for all languages (which is probably not a good idea, but you could use this approach and limit it to a known set of languages), you could override the on-execute method of the

Re: [racket-users] sharing a value between a DrRacket tool and a user program

2017-05-16 Thread Vincent St-Amour
John, Austin, You can use loggers for this. The `data` argument to `log-message` allows payloads to be carried along with log messages. Just have the user program log messages with a particular topic, and have the tool listen on that topic. That's how the optimization coach (which is a DrRacket

[racket-users] sharing a value between a DrRacket tool and a user program

2017-05-16 Thread 'John Clements' via Racket Users
Austin Sparks (cc:ed) and I are struggling with what I believe should be a pretty simple problem; how can we share a value between a DrRacket tool and a user’s program? Specifically, the value in question here is a channel (probably an asynchronous channel) on which the user’s thread can place