abmclin
2018-1-23 13:57:00

@samth thanks! That package does look more comprehensible.


pocmatos
2018-1-23 14:02:07

Is there a way to create a sandboxed function where it cannot access any variable defined outside it’s environment (i.e. can only access arguments and variables defined inside it?) I am refactoring a program and something like this would come in handy.


aleitch020
2018-1-23 14:07:09

@aleitch020 has joined the channel


aleitch020
2018-1-23 14:23:07

@pocmatos I haven’t had to do that myself, but about using namespaces (https://docs.racket-lang.org/guide/mk-namespace.html)?


joelmccracken
2018-1-23 18:26:42

i just saw pyret, interesting development


blerner
2018-1-23 18:33:56

:slightly_smiling_face:


leafac
2018-1-23 19:40:03

I have a complex data structure that I want to explore in DrRacket. Something like the collapsible view for syntax objects would be perfect (see image below). How do I do it?


leafac
2018-1-23 19:40:11


leafac
2018-1-23 19:54:11

Brilliant! Thank you :grinning:


keith.monihen
2018-1-23 22:41:45

@keith.monihen has joined the channel


dedbox
2018-1-24 02:06:40

Is there a way to convert (-> input-port? any/c) to a predicate? I see functions for checking arity but not return values.


ben
2018-1-24 02:08:27

I guess you can do (lambda (x) (contract-first-order-passes? (-> input-port? any/c) x))


lexi.lambda
2018-1-24 02:09:54

It isn’t possible to know if a function will work with a particular argument without calling it, at least not without knowing its source code and trying to perform some kind of static analysis.


lexi.lambda
2018-1-24 02:11:00

Which is why a contract like (-> input-port? any/c) will only raise a violation for returning multiple values if the function is actually called.


dedbox
2018-1-24 02:11:46

cool, thanks