Yeah, that would be great. We had a bit of a discussion of this sort of functionality on the slime-devel mailing list. Nobody had any easy answers, even for just SBCL and CCL, which I would have settled for. It was also pointed out that there's a basic first level of functionality, permitting meta-. to work. Then, the next level preserves source location of subforms of a body of Lisp code to support "PC to Source" mapping. This doesn't seem all that hard to do at least a first-level version, at least with the stuff SLIME can already do. And then encapsulating it in a Library would be great. Excellent library candidate. Hope someone will do this -- it will be really worthwhile and make a lot of developers happy.
On 3/28/2011 3:10 PM, Ben Hyde wrote: > On Mar 28, 2011, at 11:14 AM, Mark H. David wrote: >> Can you explain a bit what you mean by this? > > > My example. Say I have a macro for defining widgets and I use it I > define cool-widget on line N of file foo.lisp like so: > > (define-widget cool-widget ...) > > In the wonderful world which is my imagination I should be able to > meta-dot the symbol cool-widget > and shortly there after find my self visiting line N of foo.lisp. > > This presumes that each implementation supports the concept of > definition homes for - a mapping from > keys of some sort (typically a symbol) to source location(s). The > author of define-widget would add > entries to that mapping. The IDE (slime say) would query that mapping. > > The author of define-widget might write something like so: > > (defmacro define-widget (name ...) > ... > `(progn > (take-note-of-definitional-home ,name ... :widget ...) > ...)) > > The kind implementor of the 'implementation independent library that > abstracts out the > recording of the "definitional home"' would know how to map the > arguments to take-note-of-definitional-home > into something that actually adds/revises an entry into the > implemenation's mapping. > > It would be a wonderful world, yes it would. > > - ben > _______________________________________________ pro mailing list [email protected] http://common-lisp.net/cgi-bin/mailman/listinfo/pro
