On Thu, 2009-09-03 at 23:46 +0300, Abdulaziz Ghuloum wrote: > On Sep 3, 2009, at 9:30 AM, Derick Eddington wrote: > > >> (define A (make-record-type-descriptor 'A #F #F #F #F '#())) > >> (match 1 > > ((:record A) 'record) > > (_ 'nope)) > > Unhandled exception > > Condition components: > > 1. &who: record-type-descriptor > > 2. &message: "not a record type" > > 3. &syntax: > > form: (record-type-descriptor A) > > subform: #f > > 4. &trace: #<syntax (record-type-descriptor A)> > > 5. &trace: #<syntax (match-lambda ((:record A) 'record) (_ 'nope))> > > 6. &trace: #<syntax (match 1 ((:record A) 'record) (_ 'nope))> > >> (match 1 > > ((:record (RTD A)) 'record) > > (_ 'nope)) > > nope > > Side question: Are the expansion traces shown above helpful > in understanding the potential cause of the error? Could > they be improved (without adding a full-fledged debugger, > e.g., DrScheme)?
I've found them adequately helpful. I like how it currently is. I don't know how it could be improved, but that's because I don't know what's possible. When I try running this in DrScheme: #!r6rs (import (rnrs) (xitomatl match)) (define A (make-record-type-descriptor 'A #F #F #F #F '#())) (match 1 ((:record A) 'record) (_ 'nope)) I just get: expand: unbound identifier in module in: descriptor When I try it in DrScheme's macro stepper, I get lost in the enormous amount of other stuff expanded before it gets to the problem, and when it does get to the problem, it just tells me the same "expand: unbound identifier in module in: descriptor". -- : Derick ----------------------------------------------------------------
