<dzoe>
What would be the best way to specify arbitrary valid values in contract? Like in parameter/c where the parameter should be an integer and one of 1 2 7 10 or 12 (for example).
<dzoe>
I ended up with something like (and/c integer? (curryr member '(1 2 7 10 12))
<dzoe>
Probably works, but looks ugly in the documentation ...
lavaflow has quit [Quit: WeeChat 2.7]
lavaflow has joined #racket
<dzoe>
And how to create multiple defines using one syntax? I am trying to create a define-something that would basically create (define something 1) and (define (something? x) #t) (of course, doing something reasonable).
<dzoe>
Basically unsyntax-splicing is what I am looking for - but I have no idea, how to leverage that in define-syntax context.
<dzoe>
Never mind... writing faster than thinking.
<dzoe>
Grouping in (begin ...) does not create a new continuation frame and therefore my defines stay at the top level.
gour has quit [Remote host closed the connection]
gour has joined #racket
dddddd_ has joined #racket
dddddd has quit [Ping timeout: 260 seconds]
dddddd_ is now known as dddddd
vraid has joined #racket
efm has quit [Ping timeout: 240 seconds]
dddddd has quit [Quit: ]
dddddd has joined #racket
englishm has quit []
englishm has joined #racket
orivej has quit [Ping timeout: 260 seconds]
badkins has joined #racket
badkins has quit [Ping timeout: 260 seconds]
pera has joined #racket
badkins has joined #racket
endformationage has joined #racket
badkins has quit [Ping timeout: 268 seconds]
<greghendershott>
dzoe: On your first question, how about `(or/c 1 2 7 10 12)` ?
boeg has quit []
boeg has joined #racket
<greghendershott>
On your second: I've needed any "fancy" splicing beyond `begin`. Someday maybe I'll write a macro exciting enough to need more, but so far I guess I'm too boring.
dddddd has quit [Ping timeout: 260 seconds]
<dzoe>
:) Thanks
orivej has joined #racket
badkins has joined #racket
vraid has quit [Quit: Leaving]
badkins has quit [Ping timeout: 260 seconds]
nullcone has joined #racket
narimiran has quit [Ping timeout: 260 seconds]
zmv has joined #racket
narimiran has joined #racket
Fernando-Basso has quit [Quit: Leaving]
FreeFull has joined #racket
wingo has joined #racket
vraid has joined #racket
Sgeo__ has joined #racket
Sgeo_ has quit [Ping timeout: 260 seconds]
dddddd has joined #racket
gour has left #racket ["Leaving"]
Fernando-Basso has joined #racket
nullcone has quit [Quit: Connection closed for inactivity]
Sauvin has quit [Ping timeout: 268 seconds]
boeg has quit [Ping timeout: 246 seconds]
englishm has quit [Ping timeout: 245 seconds]
nullcone has joined #racket
cky has quit [Quit: WeeChat 2.3]
acarrico has quit [Ping timeout: 252 seconds]
narimiran has quit [Ping timeout: 265 seconds]
manumanumanu has quit [Read error: Connection reset by peer]
samlamamma has joined #racket
zmv has quit [Read error: Connection reset by peer]
efm has joined #racket
Fernando-Basso has quit [Quit: Leaving]
ZombieChicken has joined #racket
samlamamma has quit [Ping timeout: 268 seconds]
Sgeo_ has joined #racket
cky has joined #racket
Sgeo__ has quit [Ping timeout: 240 seconds]
pilne has joined #racket
dustyweb has quit [Ping timeout: 245 seconds]
sagax has quit [Remote host closed the connection]
sagax has joined #racket
englishm has joined #racket
boeg has joined #racket
orivej has quit [Ping timeout: 272 seconds]
badkins has joined #racket
badkins has quit [Remote host closed the connection]