From mb at bese.it Mon Oct 4 17:15:48 2004 From: mb at bese.it (marco) Date: Mon, 04 Oct 2004 19:15:48 +0200 Subject: [Bese-devel] :template options referring to data within the "current" component In-Reply-To: (Anthony Juckel's message of "Mon, 20 Sep 2004 20:53:24 -0500") References: Message-ID: Anthony Juckel writes: > Is there a way to refer to the current component when supplying > :template options? there's a better way to do this. i'm going to remove the :template option from the defcomponent macro and replace it with: (defclass template-component (standard-component) ((template-name :accessor template-component.template-name :initarg :template-name :allocation :class))) (defgeneric template-environment (template-component)) (defmethod template-environment ((component template-component)) (make-tal-environement 'component component)) changing the template name is a simple matter of defining a new method on the function template-component.template-name. this has a few of added benefits: 1) extending a super class' environment is easy. 2) anthony has a clane way to decide the template name based on the context or the response or the component or whatever. 3) less vodoo majick macros (there is a point where macros become opaque, defcomponent is close to, if not beyond, that point). i have only one doubt, the default implementation of template-component.template-name will simply access the template-name slot in the component, should the allocation of this slot be :class or :instance? this work (along with other big component api changes) will happen on the ucw--component-mop--dev--0.3 branch. -- -Marco Ring the bells that still can ring. Forget your perfect offering. There is a crack in everything. That's how the light gets in. -Leonard Cohen From mb at bese.it Mon Oct 4 17:51:48 2004 From: mb at bese.it (Marco Baring) Date: Mon, 04 Oct 2004 19:51:48 +0200 Subject: [Bese-devel] UCW component API (Mr. MOP rears his ugly head) Message-ID: on the ucw--component-mop--0.3 branch you can now find a version of the component protocol which uses the MOP and not the defcomponent macro. what's changed: 1) the defcomponent macro is gone having been replaced by defclass with a :metaclass of standard-component-class. what this means in practice is that much of the work done by defcomponent is now accessable to developers, as far as i'm concerned this alone justifies the MOP's learning curve and the change in API. 2) the value passed to the :component slot option is no longer a form but a type (and is not evaluated) 3) the value passed to the :backtrack slot option is no longer a function but a function name (and is not evaluated) 4) user defined shared-initialize methods are safe (previously they caused lots of important things to not happen). 5) the :entry-point defcomponent option is gone (not that (afaik) anyone ever used this). 6) the :template class option is gone, having been replaced by a template-component class and the method template-component-environment (see the other mail for details). comments? i haven't (and don't plan on) merging this with the dev branch for a while. i'm going to use it a bit and see how it fells before passing judgement (which is not to say i may re-introduce defcomponent). (brief arch tangent: how do i get the ucw--component-mop--0.3 branch? $ tla get ucw-2004 at common-lisp.net/ucw--component-mop--0.3 $ ln -s ucw--component-mop--0.3 ucw ) happy hacking. -- -Marco Ring the bells that still can ring. Forget your perfect offering. There is a crack in everything. That's how the light gets in. -Leonard Cohen From joelh at piquan.org Thu Oct 7 01:43:54 2004 From: joelh at piquan.org (Joel Ray Holveck) Date: Wed, 06 Oct 2004 18:43:54 -0700 Subject: [Bese-devel] Bug in yaclml inhibits compilation under LispWorks Message-ID: <87wty3mhet.fsf@thor.piquan.org> In yaclml, in src/tal/xmls.lisp there's the form: (define-condition xml-parse-error (error) ((line :initarg :line :reader :error-line))) Perhaps the reader should be error-line, not :error-line. LispWorks traps the function definition as an error. I have no idea how to report this as a bug, and I'm not on the lists. Is there anything in particular I should do? Cheers, joelh -- Joel Ray Holveck - joelh at piquan.org Fourth law of programming: Anything that can go wrong wi sendmail: segmentation violation - core dumped From mb at bese.it Mon Oct 11 07:44:49 2004 From: mb at bese.it (marco) Date: Mon, 11 Oct 2004 09:44:49 +0200 Subject: [Bese-devel] Bug in yaclml inhibits compilation under LispWorks In-Reply-To: <87wty3mhet.fsf@thor.piquan.org> (Joel Ray Holveck's message of "Wed, 06 Oct 2004 18:43:54 -0700") References: <87wty3mhet.fsf@thor.piquan.org> Message-ID: Joel Ray Holveck writes: > In yaclml, in src/tal/xmls.lisp there's the form: > (define-condition xml-parse-error (error) > ((line :initarg :line > :reader :error-line))) > > Perhaps the reader should be error-line, not :error-line. LispWorks > traps the function definition as an error. i'd think so. i've patched yaclml's copy of xmls and i'll notify miles (the author of xmls). -- -Marco Ring the bells that still can ring. Forget your perfect offering. There is a crack in everything. That's how the light gets in. -Leonard Cohen From mb at bese.it Thu Oct 14 18:36:59 2004 From: mb at bese.it (marco) Date: Thu, 14 Oct 2004 20:36:59 +0200 Subject: [Bese-devel] tal template inclusion Message-ID: has anybody who uses tal:include longed for anonymous (or inline or however you want to call them) templates? -- -Marco Ring the bells that still can ring. Forget your perfect offering. There is a crack in everything. That's how the light gets in. -Leonard Cohen From rm at fabula.de Thu Oct 14 18:45:25 2004 From: rm at fabula.de (rm at fabula.de) Date: Thu, 14 Oct 2004 20:45:25 +0200 Subject: [Bese-devel] tal template inclusion In-Reply-To: References: Message-ID: <20041014184525.GA14827@www> On Thu, Oct 14, 2004 at 08:36:59PM +0200, marco wrote: > > has anybody who uses tal:include longed for anonymous (or inline or > however you want to call them) templates? Hi Marco, somehow i don't seem to get it: what do you mean by "anonymous"? Or "inline"? Ralf Mattes > -- > -Marco > Ring the bells that still can ring. > Forget your perfect offering. > There is a crack in everything. > That's how the light gets in. > -Leonard Cohen > > _______________________________________________ > bese-devel mailing list > bese-devel at common-lisp.net > http://common-lisp.net/mailman/listinfo/bese-devel From mb at bese.it Thu Oct 14 18:49:33 2004 From: mb at bese.it (Marco Baringer) Date: Thu, 14 Oct 2004 20:49:33 +0200 Subject: [Bese-devel] tal template inclusion In-Reply-To: <20041014184525.GA14827@www> (rm@fabula.de's message of "Thu, 14 Oct 2004 20:45:25 +0200") References: <20041014184525.GA14827@www> Message-ID: rm at fabula.de writes: > somehow i don't seem to get it: what do you mean by "anonymous"? > Or "inline"? a way to include another template without having to create a seperate tal file. you'd create and name a template from within the file that uses it, this would (in those admitedly very rare cases) avoid having multiple very small tal files which are only included in one other file. -- -Marco Ring the bells that still can ring. Forget your perfect offering. There is a crack in everything. That's how the light gets in. -Leonard Cohen From rm at fabula.de Thu Oct 14 18:56:56 2004 From: rm at fabula.de (rm at fabula.de) Date: Thu, 14 Oct 2004 20:56:56 +0200 Subject: [Bese-devel] tal template inclusion In-Reply-To: References: <20041014184525.GA14827@www> Message-ID: <20041014185656.GB14827@www> On Thu, Oct 14, 2004 at 08:49:33PM +0200, Marco Baringer wrote: > rm at fabula.de writes: > > > somehow i don't seem to get it: what do you mean by "anonymous"? > > Or "inline"? > > a way to include another template without having to create a seperate > tal file. you'd create and name a template from within the file that > uses it, this would (in those admitedly very rare cases) avoid having > multiple very small tal files which are only included in one other > file. Ah, i see. But isn't that the job of the TAL provider anyway? Just create an "in-memory" TAL-provider and a method to add "inline"/not file based TALs to it. I can hack up something like that (i have some code somewhere that does something like that) if you want me too. RalfD > -- > -Marco > Ring the bells that still can ring. > Forget your perfect offering. > There is a crack in everything. > That's how the light gets in. > -Leonard Cohen From mb at bese.it Fri Oct 22 18:17:07 2004 From: mb at bese.it (Marco Baringer) Date: Fri, 22 Oct 2004 20:17:07 +0200 Subject: [Bese-devel] more UCW api breakage Message-ID: i wasted a lot of time because i kept writing: ( Is there any tool for emacs or not, for lisp refactoring? I think to a code transformation utility rule-based that takes as input a stream with lisp code, a rule and generate as output the new version API compliant lisp code. So an api breakage can be delivered with the rule that transform the matching code. Sorry for my English > > i wasted a lot of time because i kept writing: > > ( > instead of > > ( > the problem is that in a bout of madness i defined some > this will break old code (though that seems to be ucw 0.3's motto), if anyone has issues with this (or other recent changes) i'm all > ears. qui tacet consentire videtur. > > -- > -Marco > Ring the bells that still can ring. > Forget your perfect offering. > There is a crack in everything. > That's how the light gets in. > -Leonard Cohen > > _______________________________________________ > bese-devel mailing list > bese-devel at common-lisp.net > http://common-lisp.net/mailman/listinfo/bese-devel > From dirk at dirkgerrits.com Sat Oct 23 13:34:25 2004 From: dirk at dirkgerrits.com (Dirk Gerrits) Date: Sat, 23 Oct 2004 15:34:25 +0200 Subject: [Bese-devel] Re: Lisp refactoring In-Reply-To: <32960.10.0.7.61.1098486084.squirrel@10.0.7.61> (matley@muppetslab.org's message of "Sat, 23 Oct 2004 01:01:24 +0200 (CEST)") References: <32960.10.0.7.61.1098486084.squirrel@10.0.7.61> Message-ID: <877jphpnha.fsf@dirkgerrits.com> "Matley" writes: > Is there any tool for emacs or not, for lisp refactoring? I know of no working system, but this paper may interest you: http://www.gia.ist.utl.pt/%7Eaml/Links/pattern-language-for-refactoring.ps Perhaps some one could turn the described system into a nice addition to SLIME? Kind regards, Dirk Gerrits From mb at bese.it Sun Oct 24 15:03:33 2004 From: mb at bese.it (marco) Date: Sun, 24 Oct 2004 17:03:33 +0200 Subject: [Bese-devel] On Documentation Message-ID: i've been asking myself the past few days how i should do thingto do things like: download your file and have the value returned by (get-file-download-url $file-component) be used for the href attribute. i was worrying about what syntax to chose and how to implement it. turns out tal already supports this via the ${ and @{ syntax...and it's even documentatied. not only must i write documentation, not only must i keep it up to date with the source, i even have to read the stuff every now and then! -- -Marco Ring the bells that still can ring. Forget your perfect offering. There is a crack in everything. That's how the light gets in. -Leonard Cohen