[racket-users] Re: how can I approximate syntax properties with `make-rename-transformer`?

2017-11-28 Thread Jack Firth
What about passing the configuration data to `other-module-begin` via keyword arguments or tagged expressions in the body of the `(other-module-begin ...)` expansion? Is there a particular reason `mb` and `other-module-begin` need to communicate with syntax properties? On Tuesday, November 28,

Re: [racket-users] Re: #lang languages and cyclic dependencies

2017-11-28 Thread Jack Firth
Huh, I must have missed this the first time around. I've run into this sort of thing multiple times before and it usually brings me to this question: What if the configuration file was the main module of your app, instead of something imported by your app? Think about it. The

Re: [racket-users] Unit test inner procedures

2017-11-28 Thread Jack Firth
I like it. Added an issue to figure out a Rackety way to do this; feedback strongly encouraged. On Tuesday, November 28, 2017 at 11:05:50 AM UTC-8, Benjamin Lerner wrote: > > (Pyret co-lead dev here.) > > The way nested tests work for us in Pyret is

[racket-users] how can I approximate syntax properties with `make-rename-transformer`?

2017-11-28 Thread Matthew Butterick
I'm making a #%module-begin macro, but I want to delegate it to an existing one. OK, let's start with a rename transformer: (provide (rename-out [mb #%module-begin])) (define-syntax mb (make-rename-transformer #'other-module-begin)) (define-syntax other-module-begin (λ (stx) #'foo)) That

[racket-users] or/c, parametric->/c, and contract-first-order-passes?

2017-11-28 Thread Ben Greenman
The other day, I wanted to write a contract for a function that takes any kind of vector and does something depending on whether the vector is mutable. The contract was basically the one below: ``` #lang racket (define/contract (f v) (parametric->/c [A] (-> (or/c (vectorof A #:immutable

Re: [racket-users] Assigning actions to any key on a terminal

2017-11-28 Thread Cleverson Casarin Uliana
Hi, OK, I'll look for the console API, or installing Linux/BSD on a virtual machine, or even go experiment with racket/gui, since it's just a little project mostly for fun. :) Greetings Cleverson -- You received this message because you are subscribed to the Google Groups "Racket Users"

Re: [racket-users] Assigning actions to any key on a terminal

2017-11-28 Thread Neil Van Dyke
Cleverson Casarin Uliana wrote on 11/28/2017 05:12 PM: Hello, I'd like a library to detect any key press on a terminal (from single characters to key combinations), so I can perform diverse actions when one is pressed. I tried the charterm package, but it seems not compatible with the Windows

[racket-users] Assigning actions to any key on a terminal

2017-11-28 Thread Cleverson Casarin Uliana
Hello, I'd like a library to detect any key press on a terminal (from single characters to key combinations), so I can perform diverse actions when one is pressed. I tried the charterm package, but it seems not compatible with the Windows standard console, since it reports it cannot find

Re: [racket-users] unexpected behavior of parametric polymorphism in Typed Racket

2017-11-28 Thread Daniel Feltey
Sorry for the late reply to this thread, I tried to send this message yesterday, but ran into problems with my email setup. > I'm starting to think that my base assumption (that Typed Units are more or > less equivalent to ML signatures, structures, and functors) is way off. The intent is that

Re: [racket-users] Re: #lang languages and cyclic dependencies

2017-11-28 Thread Philip McGrath
For the benefit of posterity, while I haven't actually solved the cycle-in-loading error, I was able to get the results that I wanted in this case by: 1. Implementing the language as a `module` (not `module*` or `module+`) submodule of "my-project/config.rkt", including a (module reader

Re: [racket-users] Unit test inner procedures

2017-11-28 Thread Benjamin Lerner
(Pyret co-lead dev here.) The way nested tests work for us in Pyret is actually simpler than that: As a dummy example, consider a curried addition function |fun make-adder(num1 :: Number): fun result(num2 :: Number): num1 + num2 where: result(5) is num1 + 5 result(10) is num1 + 10 end result

Re: [racket-users] Unit test inner procedures

2017-11-28 Thread Jack Firth
> > BUT, one could easily imagine an extension to the unit testing framework > where inner tests work, too. With a combination of coverage and unit > testing, you can usually get these inner unit tests to run and record their > status the same way outer ones do in module+. Pyret, for example,

Re: [racket-users] Unit test inner procedures

2017-11-28 Thread Matthias Felleisen
+2(that’s what the style guide says, too) BUT, one could easily imagine an extension to the unit testing framework where inner tests work, too. With a combination of coverage and unit testing, you can usually get these inner unit tests to run and record their status the same way outer

Re: [racket-users] unexpected behavior of parametric polymorphism in Typed Racket

2017-11-28 Thread Matthias Felleisen
> On Nov 28, 2017, at 10:02 AM, Richard Cobbe wrote: > > On Tue, Nov 28, 2017 at 09:43:54AM -0500, Matthias Felleisen wrote: >> >> I have forwarded your email to Daniel Felty who designed and implemented the >> typed units. I am hoping to get a response soon — Matthias > >

Re: [racket-users] unexpected behavior of parametric polymorphism in Typed Racket

2017-11-28 Thread Richard Cobbe
On Tue, Nov 28, 2017 at 09:43:54AM -0500, Matthias Felleisen wrote: > > I have forwarded your email to Daniel Felty who designed and implemented the > typed units. I am hoping to get a response soon — Matthias Great, thanks. > > On Nov 26, 2017, at 6:11 PM, Richard Cobbe

Re: [racket-users] unexpected behavior of parametric polymorphism in Typed Racket

2017-11-28 Thread Matthias Felleisen
I have forwarded your email to Daniel Felty who designed and implemented the typed units. I am hoping to get a response soon — Matthias > On Nov 26, 2017, at 6:11 PM, Richard Cobbe wrote: > > Returning to this after a long delay... > > On Sat, Nov 11, 2017 at 01:34:05PM