[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: sh-script beg-end of function
From: |
Andreas Röhler |
Subject: |
Re: sh-script beg-end of function |
Date: |
Thu, 22 Nov 2007 19:56:14 +0100 |
User-agent: |
KMail/1.9.5 |
Am Donnerstag, 22. November 2007 18:39 schrieb Stefan Monnier:
> > However, in this case, making `defun-prompt-regexp' a
> > lokal variable away from customization seems not the
> > appropriate way. I suggest to let the user decide about
> > this regexp and make this decision available for all
> > sh-scripts.
>
> If you can give me some examples of other regexps which might be
> sometimes (but not always) preferable, send them along.
>
> > Functions don't play the role in sh-scripts as in other
> > languages code.
>
> Don't they? Can you expand on this?
>
> > So it's probably not useful to require
> > a "()" in that regexp.
>
> It requires either () or `function'. That's how the Bash manpage
> documents their syntax of functions.
>
> > Can't figure out your solution
> > for `end-of-defun-function'.
>
> See the docstring of end-of-defun. It'll just jump to the closing }.
>
>
> Stefan
>
The misunderstanding we seem to have might lie in
different interpretation of what's at stake.
Your code adresses a function in it's literally sence,
whereas my code adresses "top-level-form", a more
abstract thing. A "top-level-form" form BTW already
is adressed by Emacs-Lisp `end-of-defun' or
`beginning-of-defun' and I already remarked the naming
as somehow misleading therefore, but that's a matter
from the past.
Now, jumping to the beginning of a top-level-form
doesn't mean necessarily beginning of a function and
"end" must not mean end of a function, however it can.
My "end"-code expresses something like "end of last part of
code before beginning of next toplevel-form, if any, or
end of last part..."
Certainly we may discuss if that interpretation useful or not.
Andreas Röhler
- sh-script beg-end of function, Andreas Röhler, 2007/11/19
- Re: sh-script beg-end of function, Richard Stallman, 2007/11/21
- Re: sh-script beg-end of function, Andreas Röhler, 2007/11/21
- Re: sh-script beg-end of function, Stefan Monnier, 2007/11/21
- Re: sh-script beg-end of function, Andreas Röhler, 2007/11/22
- Re: sh-script beg-end of function, Stefan Monnier, 2007/11/22
- Re: sh-script beg-end of function,
Andreas Röhler <=
- Re: sh-script beg-end of function, Stefan Monnier, 2007/11/22
- Re: sh-script beg-end of function, Andreas Röhler, 2007/11/23
- Re: sh-script beg-end of function, Stefan Monnier, 2007/11/23
- Re: sh-script beg-end of function, Andreas Röhler, 2007/11/24
- Re: sh-script beg-end of function, Andreas Röhler, 2007/11/23