axiom-developer
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Axiom-developer] Literated VMLISP.LISP.PAMPHLET


From: Ralf Hemmecke
Subject: Re: [Axiom-developer] Literated VMLISP.LISP.PAMPHLET
Date: Fri, 22 Sep 2006 17:14:36 +0200
User-agent: Thunderbird 1.5.0.7 (X11/20060909)

Not quite. This whole BL*H thing is thoroughly confusing. I'll just
give you the real code (kind of).

File1:

(defmacro alias-for-foo (...)
  [code generating code calling foo])

(defun bar (...)
  ...)

(defun define-function (alias function)
  (setf (symbol-function alias) function))

(define-function alias-for-bob #'bob)

End of File1

FOO and BOB are functions defined elsewhere. Now I wanted to put all
(most) aliases in a single chunk since they don't deserve individual
documentation. Hence the first and last forms above go into a single
chunk:

<<aliases>>=
(defmacro alias-for-foo (...)
  [code generating code calling foo])

(define-function alias-for-bob #'bob)
@

Hmmm, I am not sure I can support that approach. For two reasons.

1) Most probably the aliases come in the documentation without links to the code they refer to. (Though that can be done.)

2) You separate code that belongs together. Don't you think?

Why would it make sense to list all the abbreviations on one section (even without documenation)?

Thanks for taking the time to discuss - admittedly boring - details.

I don't think that it is "boring". I am sure that most of us have no real experience what the best LP style in Axiom would be. Otherwise I would have seen a "Conventions" page that explains how to write good literate programs. It's not totally clear, at least not for me.

But all our experiences must be collected some day on the wiki or another document to help newcomers with this LP style in Axiom. It's important.

Ralf




reply via email to

[Prev in Thread] Current Thread [Next in Thread]