Re: [racket] using scribble/eval in conjunction with scribble/lp

2015-01-05 Thread Joel McCracken
I think I've successfully written the macro: (define-syntax (lit-examples stx) (syntax-case stx () [(_ e ...) #`(begin (let ([evaluator (make-base-eval)] [here (quote-source-file #,stx)]) (evaluator `(begin (dynamic-require '

Re: [racket] Void expression found

2015-01-05 Thread Jack Firth
Given that racket has multiple return values, what sort of issues would arise if functions were allowed to return no values at all instead of opting to return the single value void when they have nothing to return? Is it purely a backwards compatibility thing, or are there more fundamental problems

Re: [racket] Void expression found

2015-01-05 Thread Hendrik Boom
On Mon, Jan 05, 2015 at 05:58:31PM -0500, Sean Kanaley wrote: > I see "void" as a tangible value specifying no information, whereas > "undefined" is literally no information. So void is more like an empty > universe and undefined is no universe at all. Algol 68 had a void value, called 'empty' in

Re: [racket] Understanding local-expand with definition contexts

2015-01-05 Thread Ryan Culpepper
Here’s an alternative solution as a trampolining* macro. The key is to cooperates with the unit macro’s definition-context handling rather than trying to duplicate that effort. That’s especially important when dealing with the unit macro, since it is infeasible to duplicate its handling of unit

Re: [racket] Void expression found

2015-01-05 Thread Matthias Felleisen
MacArthur said so in '41. On Jan 5, 2015, at 6:39 PM, Robby Findler wrote: > Oh, it's there. It's just lurking, hiding, biding its time. > > All bee bak. > > Robby > > On Mon, Jan 5, 2015 at 5:13 PM, Matthias Felleisen > wrote: >> >> There is no Undefined. We got rid of it ;-) >> >> >

Re: [racket] Void expression found

2015-01-05 Thread Robby Findler
Oh, it's there. It's just lurking, hiding, biding its time. All bee bak. Robby On Mon, Jan 5, 2015 at 5:13 PM, Matthias Felleisen wrote: > > There is no Undefined. We got rid of it ;-) > > > On Jan 5, 2015, at 6:02 PM, Robby Findler wrote: > >> And yet, they are both in our current universe. >

Re: [racket] Void expression found

2015-01-05 Thread Matthias Felleisen
There is no Undefined. We got rid of it ;-) On Jan 5, 2015, at 6:02 PM, Robby Findler wrote: > And yet, they are both in our current universe. > > On Mon, Jan 5, 2015 at 4:58 PM, Sean Kanaley wrote: >> I see "void" as a tangible value specifying no information, whereas >> "undefined" is lite

Re: [racket] Void expression found

2015-01-05 Thread Robby Findler
And yet, they are both in our current universe. On Mon, Jan 5, 2015 at 4:58 PM, Sean Kanaley wrote: > I see "void" as a tangible value specifying no information, whereas > "undefined" is literally no information. So void is more like an empty > universe and undefined is no universe at all. > > On

Re: [racket] Void expression found

2015-01-05 Thread Sean Kanaley
I see "void" as a tangible value specifying no information, whereas "undefined" is literally no information. So void is more like an empty universe and undefined is no universe at all. On Mon, Jan 5, 2015 at 5:40 PM, Vincent St-Amour wrote: > At Mon, 5 Jan 2015 23:20:54 +0100, > Jos Koot wrote:

Re: [racket] Void expression found

2015-01-05 Thread Vincent St-Amour
At Mon, 5 Jan 2015 23:20:54 +0100, Jos Koot wrote: > > Off topic: > For me the unanswered question remains: > Does the vacuum exist or does it not exist? > I don't know. Parmenides had something to say on the matter: http://en.wikipedia.org/wiki/Parmenides#The_Way_of_Truth Vincent ___

Re: [racket] Void expression found

2015-01-05 Thread Jos Koot
Void is a peculiar thing. It is used by Racket where no result is ment. But every expression must have a (multiple) value (if it computes in finite time) Because the value of (void) has to be considered to be the absence of a value, the repl and the interactions window do not show them. For example

Re: [racket] Understanding local-expand with definition contexts

2015-01-05 Thread Spencer Florence
Awesome! Thanks, that works for what I'm doing. On Mon Jan 05 2015 at 2:47:43 PM Matthew Flatt wrote: > That turns out to be tricky. I've enclosed an implementation, but it > works only for units that have no imports. > > At Mon, 05 Jan 2015 17:21:37 +, Spencer Florence wrote: > > What I'm t

Re: [racket] Understanding local-expand with definition contexts

2015-01-05 Thread Matthew Flatt
That turns out to be tricky. I've enclosed an implementation, but it works only for units that have no imports. At Mon, 05 Jan 2015 17:21:37 +, Spencer Florence wrote: > What I'm trying to do is capture all lifts inside a unit body, instead of > having them propagating to the top level. > > I

Re: [racket] Community effort request.

2015-01-05 Thread Juan Francisco Cantero Hurtado
On 12/26/2014 10:27 PM, gghh wrote: Ladies and gentleman, is there is request for video tutorials for Racket programing language. Cause SICP are not about language it self. Look the coursera courses: https://github.com/plt/racket/wiki/Courses-using-Racket Racket Users

[racket] Void expression found

2015-01-05 Thread Hendrik Boom
On Sun, Jan 04, 2015 at 11:25:52PM -0500, Alexander D. Knauth wrote: > will (void) not work? Only if you know it exists. Thank you. Every language has a few essential trivia that are hard to find in the documentation. Eventually you learn how the documentation is organised and you can find th

Re: [racket] Understanding local-expand with definition contexts

2015-01-05 Thread Spencer Florence
What I'm trying to do is capture all lifts inside a unit body, instead of having them propagating to the top level. If I understand what you mean by "add internal-definition context to the bindings listed in `exports`", I can't do that because I need to capture any lifts inside the unit body, but

Re: [racket] Understanding local-expand with definition contexts

2015-01-05 Thread Matthew Flatt
I'm not really clear on what you're trying to do. One way to explain more might be to explain how `test` is meant to differ from `begin`. Or maybe you can say why it doesn't work to add the internal-definition context to the bindings listed in `exports` (i.e., to bring everything into the definitio

Re: [racket] Understanding local-expand with definition contexts

2015-01-05 Thread Spencer Florence
Is there any way to have the `test` macro work more like `begin`? What I am trying to accomplish is something like: (define-syntax (make-my-unit stx) (syntax-parse stx [(e ...) (with-syntax ([body (local-expand/capture-lifts stx )]) #'(unit (imports ...) (exports ...) bod

Re: [racket] Understanding local-expand with definition contexts

2015-01-05 Thread Matthew Flatt
I think it's more a question of what a definition context is supposed to be, rather than how `syntax-local-bind-syntaxes` works. When you create a new definition context, the context's bindings are visible only to expressions that are also in that context. The `test` form here creates a new defini

Re: [racket] Understanding local-expand with definition contexts

2015-01-05 Thread Spencer Florence
Progress is a new error! I don't think I understand how syntax-local-bind-syntaxes is supposed to work. I extended the previous program: #lang racket (require (for-syntax syntax/parse)) (define-syntax (test stx) (syntax-parse stx [(_ e) (define ctx (if (list? (syntax-local-contex

Re: [racket] Community effort request.

2015-01-05 Thread Stephen De Gabrielle
Anything in particular? On Mon Jan 05 2015 at 2:45:24 PM gghh wrote: > Ladies and gentleman, is there is request for video tutorials for Racket > programing language. Cause SICP are not about language it self. > > Regards > > Peter Smith. > > Racket Users list: > http://

Re: [racket] Understanding local-expand with definition contexts

2015-01-05 Thread Matthew Flatt
The error message is intended for "end users" and turns out to be misleading for the implementor of an internal-definition context. The documentation for `define-values` has essentially the same problem: it describes how `define-values` should work in an internal-definition context, but it doesn't

[racket] Understanding local-expand with definition contexts

2015-01-05 Thread Spencer Florence
Hey all, I'm trying to use 'local-expand', however it seems to think its never in a definition context. For example: (require (for-syntax syntax/parse)) (define-syntax (test stx) (syntax-parse stx [(_ e) (define ctx (if (list? (syntax-local-context)) (cons (gensym) (s

[racket] Community effort request.

2015-01-05 Thread gghh
Ladies and gentleman, is there is request for video tutorials for Racket programing language. Cause SICP are not about language it self. Regards Peter Smith. Racket Users list: http://lists.racket-lang.org/users