[racket] [scribble] pipe in code

From: Eric Tanter (etanter at dcc.uchile.cl)
Date: Tue Nov 22 14:14:55 EST 2011

Hi,

I want to typeset a BNF with Scheme-like syntax highlighting.

eg:

@racketblock[
<list> ::= '()
         | (cons <val> <list>)
]

except that the pipe `|' causes problem. I figured out that I can do the above with @verbatim|{...}| but then I lose the syntax highlighting ('() as a value, brown parentheses). 

Is there a way to have the pipe printed?
(or to bring back the syntax highlighting within verbatim block)

Thanks,

-- Éric





Posted on the users mailing list.