[racket-users] Help with pretty printing

2019-04-02 Thread Stephen Foster
Hi all, Suppose, I have a datum that represents valid racket code, like '(test #:a a #:b b #: c). I'd love to render (arbitrarily deeply nested) datums like this to a string that displays like this: (test #:a a #:b b #:c c) Pretty printing almost works: (displayln (pretty-format

Re: [racket-users] Error location in test submodules

2019-04-02 Thread Eric Griffis
On Tue, Apr 2, 2019 at 1:04 PM Tom Gillespie wrote: > > Are you using emacs racket-mode? I am, almost exclusively. Exception and check failure locations can be a pain, but they work in general. > On Tue, Apr 2, 2019 at 3:41 PM zeRusski wrote: >> >> If I have many test chunks spread around my

[racket-users] Error location in test submodules

2019-04-02 Thread zeRusski
I am a big fan of having tests alongside code so (module+ test ...) is magic. The only annoyance I've been running into lately is error reporting. If I have many test chunks spread around my code and some code change throws an exception or a contract violation it is impossible to tell which

[racket-users] First Call for Papers: 12th ACM SIGPLAN International Conference on Software Language Engineering (SLE 2019)

2019-04-02 Thread Andrei Chis
Call for Papers: 12th ACM SIGPLAN International Conference on Software Language Engineering (SLE 2019) co-located with SPLASH 2019 Athens, Greece October 21-22, 2019 https://conf.researchr.org/home/sle-2019

Re: [racket-users] Generate really large random numbers in Racket

2019-04-02 Thread 'Paulo Matos' via Racket Users
On 01/04/2019 23:37, Robby Findler wrote: > Generate multiples of those and combine them (shifting old ones over > and adding new ones as the lowest digits)? > > I'm not sure of a good way to generate nats uniformly at random where > you don't specify an upper bound, but Neil Toronto suggested

Re: [racket-users] Generate really large random numbers in Racket

2019-04-02 Thread 'Paulo Matos' via Racket Users
Check the math library by Neil Toronto: https://docs.racket-lang.org/math/base.html?q=random#%28part._.Random_.Number_.Generation%29 (random-natural k) → Natural k : Integer Returns a random natural number less than k, which must be positive. Use (random-natural k) instead of