Re: [racket-users] [racket users] Macro literal "|"

2020-02-03 Thread Stephen Chang
As mentioned, to get your macro to work, you have to change how the reader behaves on "|". You might be interested in the (implementation of) no-vert-bar reader lang: https://docs.racket-lang.org/no-vert-bar-lang/index.html On Mon, Feb 3, 2020 at 6:27 PM Kevin Forchione wrote: > > Hi guys, >

Re: [racket-users] [racket users] Macro literal "|"

2020-02-03 Thread Philip McGrath
You're right that `|` isn't a valid terminal with the normal reader, but, as it happens, the zero-length identifier can be written as `||`. (I don't think the concept of a zero-length identifier is common in other languages: it corresponds to the empty string.) -Philip On Mon, Feb 3, 2020 at

[racket-users] [racket users] Macro literal "|"

2020-02-03 Thread Kevin Forchione
Hi guys, I’ve been trying to figure out how to use “|” in a macro. I’ve got syntax like this in mind: (foo A | B) Not sure if I can do this because the reader expects a pair. If “|” isn’t a convenient literal to work with is there an alternative others have used that represents more

Re: [racket-users] Rolling dice game

2020-02-03 Thread Ryan Culpepper
On 2/3/20 12:31 PM, Wilzoo wrote: Hi guys, so I am working on rolling dice game in GUI, the game rules will be something like rolling 3 dices and then giving out points to 2 players based on the rolled values. Im now stuck on the showing value in GUI. Basically what I need is to show rolled

[racket-users] Rolling dice game

2020-02-03 Thread Wilzoo
Hi guys, so I am working on rolling dice game in GUI, the game rules will be something like rolling 3 dices and then giving out points to 2 players based on the rolled values. Im now stuck on the showing value in GUI. Basically what I need is to show rolled value somewhere in frame. This is