
+1 for that feature. Right now I usually make a install.rkt
file that calls raco pkg install (list of dependencies)
but it would be great to have something like the pip install -r requirements.txt
of Python or the Ruby gemfiles.

I am starting to play with syntax-parse
and define-syntax-class
. Is there a way to have keywords in the middle of a pattern as a literal-datum?

I have: (begin-for-syntax
(define-syntax-class field-spec
#:attributes (idx name-list cst)
#:datum-literals (#:names #:static)
(pattern
(idx:nat #:names name-list:expr #:static cst:nat))
(pattern
(idx:nat #:names name-list:expr)
#:with cst #'#false))

but it results in:

; registerbank-impl.rkt:17:22: define-syntax-class: expected datum-literal entry
; at: #:names

i am using keywords for no obvious reason, I simply like how they look.

@pocmatos keywords (and numbers, booleans, strings, etc) already act as literals in a pattern; the #:literals
and #:datum-literals
lists are only necessary for identifiers

ah ok, so I don’t need to specify them as literals in the pattern
form?

right

it works!!! :slightly_smiling_face: thx

FWIW A guide to use Racket with Sublime Text 3: https://gist.github.com/sarahlim/3f1527f8e910c36b3303346422b03409

Is there a good resource for learning about FFI in Racket OTHER than the Racket-Docs? Maybe some blogs or something with more examples.

@jboyens There are some examples here: https://github.com/racket/racket/tree/master/pkgs/racket-doc/ffi/examples

and there are blog posts here: http://prl.ccs.neu.edu/blog/2016/07/11/tutorial-racket-ffi-part-3/

@samth Awesome. Thank you so much.

@jboyens The paper on the FFI is nice too.

@jboyens I second the FFI paper, it was helpful for me too

Is there a link to the FFI paper? I’m not even sure what I might try searching for.


@robby do you know what the “preserve stacktrace” option means in the drracket language menu?


aha, thank you!

now, for a followup question: is there a way to have DrRacket use .zo files produced by raco setup
rather than always making new .zos? I thought turning errortrace off would do it, but I was wondering if I needed to also turn off preserve stacktrace… but I haven’t actually tried that yet.

@lexi.lambda I thought it already did that …

all I know is that, even with debugging turned off, drracket takes a really long time to run a file written in #lang hackett
after I’ve changed the implementation of Hackett and rebuilt with raco setup
, but subsequent runs are fast

@lexi.lambda “populate compiled directories” ?

if I turn that off, will DrRacket use existing zos? I think I was afraid that meant “load everything from source”, but maybe that doesn’t make sense…

If you turn that off, it will do what racket does.

sometimes use them and sometimes now

not

that makes more sense in retrospect

if you turn it on, it will try to make its own compiled/drracket/* and do “good things” with them that you might not want your deployment environment to do

yes, that’s reasonable. I do wonder one other thing: how does DrRacket decide which files to compile? does it whitelist <collects> so that it doesn’t try and create drracket/ subdirectories anywhere in there, or is there something more complicated?

@gcc.programmer has joined the channel