[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Debugging SMIE for sh-script.el
From: |
Kévin Le Gouguec |
Subject: |
Re: Debugging SMIE for sh-script.el |
Date: |
Thu, 02 Sep 2021 22:29:55 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
Nikolay Kudryavtsev <nikolay.kudryavtsev@gmail.com> writes:
> maybe there's another function further down
> the chain which can, smie-indent-exps that is and that's where 6 comes
> from.
See my original message. To paraphrase, with this shell buffer:
#+begin_src sh
${foo}/bar --baz \
--quux
#+end_src
With point on "--quux", this yields 6:
#+begin_src elisp
(let ((sh-indent-after-continuation nil))
(smie-indent-calculate))
#+end_src
- smie-indent-calculate runs all functions in smie-indent-functions,
- in a shell buffer, this variable only holds
(sh-smie--indent-continuation t),
- but this yields nil:
#+begin_src elisp
(let ((sh-indent-after-continuation nil))
(sh-smie--indent-continuation))
#+end_src
So what gives? I've tried Edebugging, but couldn't figure out how to
stop at a spot that made things clearer.
PS: aaand I've just read now Stefan's replies, which kill two birds in
one stone explaining both this riddle, and what the trailing "t" means.
That's the thing I was missing.
- Debugging SMIE for sh-script.el, Kévin Le Gouguec, 2021/09/02
- Re: Debugging SMIE for sh-script.el, Nikolay Kudryavtsev, 2021/09/05
- Re: Debugging SMIE for sh-script.el, Stefan Monnier, 2021/09/05
- Re: Debugging SMIE for sh-script.el, Nikolay Kudryavtsev, 2021/09/05
- Re: Debugging SMIE for sh-script.el, Stefan Monnier, 2021/09/05
- Re: Debugging SMIE for sh-script.el, Nikolay Kudryavtsev, 2021/09/05