[racket] Racket language tutorials

2013-05-02 Thread Matthew Butterick
Other than the standard docs, Danny Yoo's “Fudging Up Racket,” and Matthew Flatt’s "Creating Languages in Racket," are there other good sources of tutorials & sample code for the language-building facilities in Racket? Racket Users list: http://lists.racket-lang.org/users

Re: [racket] Macros and dynamically generating identifiers

2013-05-02 Thread Sean McBeth
I think I get it just from reading it (in bed, on the phone, annoying the wife). I had tried to do almost this very thing with datum->syntax at one point, but I had put the quotesyntax on datum->syntax, not on id directly. I don't understand why that would make a difference, it seems like it is si

Re: [racket] Macros and dynamically generating identifiers

2013-05-02 Thread Sean McBeth
Aaah, man. Thanks. Shutdown the pc for the night so u will try tomorrow. On May 2, 2013 10:35 PM, "Jay McCarthy" wrote: > You were close to what you want. Here's a version with a nice utility > and then the underlying machinery that makes it: > > #lang racket > (require (for-syntax racket/syntax)

Re: [racket] Macros and dynamically generating identifiers

2013-05-02 Thread Jay McCarthy
You were close to what you want. Here's a version with a nice utility and then the underlying machinery that makes it: #lang racket (require (for-syntax racket/syntax)) (define-syntax (double-define stx) (syntax-case stx (double-define) [(_ id val1 val2) (with-syntax ([id-1 (format-id

[racket] Macros and dynamically generating identifiers

2013-05-02 Thread Sean McBeth
Hi there! I'm pretty new to Racket, though not the basic concepts of functional programming [1] Maybe I don't need macros here at all, but it seemed like the right sort of lever when I first started, but now I'm pretty stuck[2] and I don't understand enough about the macro system yet to be able to

Re: [racket] SIGSEGV MAPERR si_code 1 fault on addr 0x7...; can't isolate or consistently reproduce in source code; stack trace points to scheme_uncopy_stack

2013-05-02 Thread Matthew Flatt
A stack overflow in scheme_uncopy_stack() sounds like a thread that is trying to jump to a continuation whose representation is corrupted. (An all-zeroed Scheme_Jmpup_Buf could have that effect, but I don't particularly trust gdb to tell us the actual content, unless you disabled optimization when

Re: [racket] SIGSEGV MAPERR si_code 1 fault on addr 0x7...; can't isolate or consistently reproduce in source code; stack trace points to scheme_uncopy_stack

2013-05-02 Thread Neil Van Dyke
I mean address space randomization in general, not stack. Neil Van Dyke wrote at 05/02/2013 08:12 PM: Perhaps only Matthew Flatt can solve this, but a few bits of info might help: * Is this running on Amazon EC2? * Have you disabled any stack randomization feature of the OS? * Are you using

Re: [racket] SIGSEGV MAPERR si_code 1 fault on addr 0x7...; can't isolate or consistently reproduce in source code; stack trace points to scheme_uncopy_stack

2013-05-02 Thread Neil Van Dyke
Perhaps only Matthew Flatt can solve this, but a few bits of info might help: * Is this running on Amazon EC2? * Have you disabled any stack randomization feature of the OS? * Are you using any FFI or C extensions in the Racket process? Neil V. Racket Users list: http:

Re: [racket] SIGSEGV MAPERR si_code 1 fault on addr 0x7...; can't isolate or consistently reproduce in source code; stack trace points to scheme_uncopy_stack

2013-05-02 Thread John Gateley
Hi, I'm not a Racket expert, but I have a little experience with core dumps. If you compiled the interpreter yourself, no one else will be able to do much with the core. But that's not the end of the world. Do you have the source/debug info option turned on when compiling? If not, recompile with

Re: [racket] DrRacket/Ubuntu 12.04 LTS

2013-05-02 Thread Neil Van Dyke
I think you're missing some diagnostic info that is easy to get. Install the "htop" program, and leave it running in a terminal window. When things seem to suddenly get slow, go to your "htop" terminal window (if you can), and look at what the RAM and swap usage bars say, and which processes

Re: [racket] Trimmed view in redex's traces?

2013-05-02 Thread J. Ian Johnson
Because I overlooked that argument. Thanks for pointing it out! -Ian - Original Message - From: "Robby Findler" To: "J. Ian Johnson" Cc: "users" Sent: Thursday, May 2, 2013 5:24:16 PM GMT -05:00 US/Canada Eastern Subject: Re: [racket] Trimmed view in redex's traces? Why not just use th

Re: [racket] Trimmed view in redex's traces?

2013-05-02 Thread Robby Findler
Why not just use the pp argument that's already there? (And I think your editor is indenting improperly; some of those lines don't seem to have changed except indentation) Robby On Thu, May 2, 2013 at 3:02 PM, J. Ian Johnson wrote: > Okay, here's a diff that hacks it in for my purposes and doe

Re: [racket] DrRacket/Ubuntu 12.04 LTS

2013-05-02 Thread Patrick King
Still having a hard time catching Racket or Ubuntu "in the act". Fortunately, this is at least in part because I haven't had many crashes lately. One thing that seems to happen fairly consistently is that I end up waiting a lot on the background syntax expansion. Sometimes Racket recovers. Sometime

Re: [racket] Trimmed view in redex's traces?

2013-05-02 Thread J. Ian Johnson
Okay, here's a diff that hacks it in for my purposes and doesn't crash. I don't know what this breaks due to the new init-field in size-snip though. Will anyone familiar with this part of the codebase please comment? Thanks, -Ian diff --git a/collects/redex/gui.rkt b/collects/redex/gui.rkt index

[racket] Trimmed view in redex's traces?

2013-05-02 Thread J. Ian Johnson
I'm trying to debug an abstract machine with some large auxiliary tables. Is there a way to make traces only show a portion of a term, but still treat the box it's in as the entire term? An additional bonus would be to drill down into a trimmed box via click or something. I don't see this in the

[racket] SIGSEGV MAPERR si_code 1 fault on addr 0x7...; can't isolate or consistently reproduce in source code; stack trace points to scheme_uncopy_stack

2013-05-02 Thread Matthew Eric Bassett
Hi all, It might be better to send this to dev@racket-lang. Then again, it might be completely useless to them. So we have a job scheduler program written in racket that handles various places and tcp clients. This program sporadically and inconsistently terminates with the following error

Re: [racket] Planet2 questions

2013-05-02 Thread Laurent
Interesting! On Thu, May 2, 2013 at 4:20 PM, Jay McCarthy wrote: > On Thu, May 2, 2013 at 8:18 AM, Laurent wrote: > > Does this mean that if I include a test suite in my package and register > it > > on PLaneT, the tests will be automatically run from your servers? > > If you put a test suite

Re: [racket] DRRacket right-click menu fragility in Linux.

2013-05-02 Thread Ray Racine
Given there was a time when things were pretty solid (within the last year??) a git bisect approach is an option for someone blessed with spare time and system. On Thu, May 2, 2013 at 10:03 AM, Tim Brown wrote: > Back on the subject of right menu fragility... > I ran a drracket up in an Xnest

Re: [racket] Planet2 questions

2013-05-02 Thread Jay McCarthy
On Thu, May 2, 2013 at 8:18 AM, Laurent wrote: > Does this mean that if I include a test suite in my package and register it > on PLaneT, the tests will be automatically run from your servers? If you put a test suite in your package and register it on our catalog, and your package is ring 0, then

Re: [racket] Planet2 questions

2013-05-02 Thread Walter Tetzner
On Tue, Apr 30, 2013 at 12:24 PM, Matthew Flatt wrote: > 2. It could mean that the package system has a built-in way to declare > dependencies not only on a particular package, but on a particular > revision of a package --- either to ensure that certain features > are available or th

Re: [racket] Planet2 questions

2013-05-02 Thread Laurent
Does this mean that if I include a test suite in my package and register it on PLaneT, the tests will be automatically run from your servers? And if some test fails, the package will not be updated for those who run `raco pkg update` ? On Thu, May 2, 2013 at 4:11 PM, Robby Findler wrote: > One t

Re: [racket] Planet2 questions

2013-05-02 Thread Jay McCarthy
Yes, this curation system is already partially in place. When you go to the main catalog, you'll see that each package has a 'ring' number where 0 = trusted, 1 = non conflicting, 2 = unknown. I have not yet set up continuous integration of ring 0, but I will soon. Also, I haven't got the documentat

Re: [racket] Planet2 questions

2013-05-02 Thread Robby Findler
One thing perhaps worth mentioning, tho, is that there will be a curated package source where we will make significant efforts to avoid "accidental" bugs like this, by automatically running test suites, etc. Something much like the process that we use for Racket's git (except that in the case of Ra

Re: [racket] DRRacket right-click menu fragility in Linux.

2013-05-02 Thread Tim Brown
Back on the subject of right menu fragility... I ran a drracket up in an Xnest server. No window manager nor desktop environment. Fragility still there. The more exciting stuff I did (selection, allowing arrows to appear with their respective "n bindings" popups) the more fragile. But still diffic

Re: [racket] Planet2 questions

2013-05-02 Thread Jay McCarthy
On Thu, May 2, 2013 at 7:29 AM, Matthew Flatt wrote: > [Jay will have to correct me if I have any part of this wrong...] Nope, it was beautiful. > At Thu, 2 May 2013 11:31:09 +0200, Laurent wrote: > As an aside, the `raco pkg update' action is not restricted to packages > installed by package na

Re: [racket] Planet2 questions

2013-05-02 Thread Laurent
That sounds all good to me! Thanks! On Thu, May 2, 2013 at 3:29 PM, Matthew Flatt wrote: > [Jay will have to correct me if I have any part of this wrong...] > > At Thu, 2 May 2013 11:31:09 +0200, Laurent wrote: > > Say I want to use a package, registered on the PLaneT catalog as X. > > First I

Re: [racket] Planet2 questions

2013-05-02 Thread Matthew Flatt
[Jay will have to correct me if I have any part of this wrong...] At Thu, 2 May 2013 11:31:09 +0200, Laurent wrote: > Say I want to use a package, registered on the PLaneT catalog as X. > First I do `raco pkg install X`. Yes. > In my Racket files, I simply use `(require X)'. Assuming that packa