dynamic-require

32 views
Skip to first unread message

jon stenerson

unread,
Feb 2, 2021, 10:31:59 PM2/2/21
to racket-users@googlegroups.com List
The previous message here prompts this ...

I have some modules with paths "A1.rkt" ... "An.rkt". In the interaction
window of DrRacket I can require any or all of them and I believe them
to be correct.

Now suppose I have a function (F) that produces one of those paths. I
try  (dynamic-require (F) #f) and there are no errors but where do the
imports go? I don't seem able to access them.

However, I can do (define quux (dynamic-require (F) 'quux) )  and then
use quux. Is there a way to bring in all the exports of (F) without
knowing the names ahead of time?

Thanks,

Jon

Laurent

unread,
Feb 3, 2021, 4:18:22 AM2/3/21
to jon stenerson, racket-users@googlegroups.com List

--
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 an email to racket-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/racket-users/333a9191-ae5e-6dd8-cebf-30bd00d87b9f%40comcast.net.

jon stenerson

unread,
Feb 3, 2021, 12:12:20 PM2/3/21
to racket...@googlegroups.com
Very good! Thank you.
Reply all
Reply to author
Forward
0 new messages