Re: [racket-users] racket/match a dictionary

2017-10-11 Thread Alexis King
> On Oct 11, 2017, at 2:56 PM, George Neuner wrote: > > Hmm. For completeness? I'm having trouble imaging why you'd want to > match a literal hash table. Or boxes. The other options make more > sense. Oh well. Imagine you’re parsing some JSON. You could parse the JSON into Racket data stru

Re: [racket-users] racket/match a dictionary

2017-10-11 Thread Alexis King
> On Oct 11, 2017, at 11:10 AM, George Neuner > wrote: > > My (maybe wrong) reading of the docs suggests that to match a hash > table, the table must be defined inline in the match clause. This isn’t really accurate. The hash-table match pattern matches a hash table itself, but it sounds like yo

[racket-users] racket/match a dictionary

2017-10-11 Thread George Neuner
Hi all, I trying to match a dictionary of terms against free form input. Many of the dictionary entries have aliases, so I'm using a custom hash table that matcheskeys by list membership. My (maybe wrong) reading of the docs suggests that to match a hash table, the table must be defined inline i