* bug#4452: 23.1; sh-learn-buffer-indent unexpectedly displays *indent* buffer
@ 2009-09-16 18:11 Reiner Steib
0 siblings, 0 replies; 3+ messages in thread
From: Reiner Steib @ 2009-09-16 18:11 UTC (permalink / raw)
To: bug-gnu-emacs
Hi,
when sh-learn-buffer-indent it t, an *indent* buffer is displayed
unexpectedly in certain situations.
To reproduce:
- Start `emacs -Q'
- M-: (add-hook 'sh-set-shell-hook 'sh-learn-buffer-indent) RET
- Do `M-x cvs-update RET' on a working directory with some *.sh file.
- Do `=' (cvs-mode-diff)
- The window layout is now:
+-------------+
| *cvs* |
| |
+-------------+
| *cvs-diff* |
| |
+-------------+
- Do `C-x o' (other-window) to jump to the *cvs-diff* buffer.
- Move around to the first diff hunk, hit `C-c C-c' (diff-goto-source)
- Expected behavior:
+-------------+
| foo.sh |
| |
+-------------+
| *cvs-diff* |
| |
+-------------+
- Actual behavior (Bug):
+-------------+
| *indent* |
| |
+-------------+
| foo.sh |
| |
+-------------+
- Content of *indent* (Occur mode):
| Indentation values for buffer foo.sh.
| 5 indentation variables have different values:
|
| 61: Variable sh-indent-for-continuation was set to 0
| 60: but was previously set to 7
| 62: Variable sh-indent-for-continuation was set to 4
| 61: but was previously set to 0
| 91: Variable sh-indent-for-continuation was set to 2
| 62: but was previously set to 4
| 99: Variable sh-indent-for-continuation was set to 4
| 91: but was previously set to 2
| 100: Variable sh-indent-for-continuation was set to 2
| 99: but was previously set to 4
|
| Comments follow default indentation.
|
| Initial value of sh-basic-offset: 4
| Suggested sh-basic-offset: 2
|
| Learned variable settings:
| sh-indent-for-case-label 0
| sh-indent-after-function 2
| sh-indent-after-if 2
| sh-indent-for-else 0
| sh-indent-for-fi 0
| sh-indent-after-loop-construct 2
| sh-indent-for-continuation 2
| sh-indent-for-done 0
| sh-indent-after-open 2
| sh-indent-comment t
In GNU Emacs 23.1.1 (i386-mingw-nt6.0.6001)
of 2009-07-30 on SOFT-MJASON
Windowing system distributor `Microsoft Corp.', version 6.0.6001
configured using `configure --with-gcc (4.4)'
Important settings:
value of $LC_ALL: nil
value of $LC_COLLATE: nil
value of $LC_CTYPE: nil
value of $LC_MESSAGES: nil
value of $LC_MONETARY: nil
value of $LC_NUMERIC: nil
value of $LC_TIME: nil
value of $LANG: DEU
value of $XMODIFIERS: nil
locale-coding-system: cp1252
default-enable-multibyte-characters: t
Major mode: Lisp Interaction
Minor modes in effect:
diff-auto-refine-mode: t
tooltip-mode: t
tool-bar-mode: t
mouse-wheel-mode: t
menu-bar-mode: t
file-name-shadow-mode: t
global-font-lock-mode: t
font-lock-mode: t
blink-cursor-mode: t
global-auto-composition-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t
line-number-mode: t
transient-mark-mode: t
Recent input:
<help-echo> <help-echo> <help-echo> <help-echo> C-x
5 f . e <tab> m <tab> i n i <tab> . <tab> <return>
<help-echo> C-s s h - C-a <down-mouse-1> <mouse-movement>
<mouse-movement> <drag-mouse-1> <switch-frame> <down-mouse-1>
<mouse-1> M-x i e <tab> <return> <S-insert> <return>
<help-echo> <help-echo> <help-echo> <help-echo> <help-echo>
<help-echo> <help-echo> M-x c v s - u <tab> <return>
<up> <up> <up> <left> <end> <home> C-k <switch-frame>
<down-mouse-1> <mouse-movement> <mouse-1> <help-echo>
<help-echo> <switch-frame> <down-mouse-1> <mouse-1>
<down-mouse-1> <mouse-1> <S-insert> <return> <help-echo>
<help-echo> <down-mouse-1> <mouse-1> <end> <left> <up>
<return> C-x b * c v <tab> <return> <up> <up> <up>
<up> = <down-mouse-1> <mouse-1> C-c C-c M-x C-g C-g
C-x 5 b s c r <home> * <end> <tab> <return> M-x r e
p o <tab> r <tab> <return>
Recent messages:
line 109
line 110
line 111
line 112
line 113
basic-offset is probably 2
Mark set
Hunk already applied
Quit [2 times]
Making completion list...
Bye, Reiner.
--
,,,
(o o)
---ooO-(_)-Ooo--- | PGP key available | http://rsteib.home.pages.de/
^ permalink raw reply [flat|nested] 3+ messages in thread
* bug#4452: 23.1; sh-learn-buffer-indent unexpectedly displays *indent* buffer
@ 2009-09-18 19:02 Chong Yidong
2009-09-19 14:25 ` Reiner Steib
0 siblings, 1 reply; 3+ messages in thread
From: Chong Yidong @ 2009-09-18 19:02 UTC (permalink / raw)
To: Reiner Steib; +Cc: 4452
> when sh-learn-buffer-indent it t, an *indent* buffer is displayed
> unexpectedly in certain situations.
>
> - Start `emacs -Q'
> - M-: (add-hook 'sh-set-shell-hook 'sh-learn-buffer-indent) RET
> - Do `M-x cvs-update RET' on a working directory with some *.sh file.
> - Do `=' (cvs-mode-diff)
> - Do `C-x o' (other-window) to jump to the *cvs-diff* buffer.
> - Move around to the first diff hunk, hit `C-c C-c' (diff-goto-source)
I can't reproduce this with trunk. I tried with the autogen.sh file in
the Emacs source tree. Does that work for you?
^ permalink raw reply [flat|nested] 3+ messages in thread
* bug#4452: 23.1; sh-learn-buffer-indent unexpectedly displays *indent* buffer
2009-09-18 19:02 bug#4452: 23.1; sh-learn-buffer-indent unexpectedly displays *indent* buffer Chong Yidong
@ 2009-09-19 14:25 ` Reiner Steib
0 siblings, 0 replies; 3+ messages in thread
From: Reiner Steib @ 2009-09-19 14:25 UTC (permalink / raw)
To: Chong Yidong; +Cc: 4452
On Fri, Sep 18 2009, Chong Yidong wrote:
>> when sh-learn-buffer-indent it t, an *indent* buffer is displayed
>> unexpectedly in certain situations.
[...]
> I can't reproduce this with trunk. I tried with the autogen.sh file in
> the Emacs source tree. Does that work for you?
Sorry for not providing a *.sh file that triggers the bug.
Try this recipe:
$ cd /path/to/trunk/emacs
$ cp -p autogen.sh autogen.sh.bak
$ head -n730 config.guess >> autogen.sh
$ emacs-23-1 -Q \
--eval "(add-hook 'sh-set-shell-hook 'sh-learn-buffer-indent)" \
-f cvs-update
- Hit RET (to confirm cvs directory)
- Move to the line with autogen.sh and do `=' (cvs-mode-diff)
- The window layout is *cvs* / *cvs-diff* (upper / lower window)
- Do `C-x o' (other-window) to jump to the *cvs-diff* buffer.
- Do `M->'
- Hit `C-c C-c' (diff-goto-source)
- The window layout is *indent* / autogen.sh (upper / lower window)
==> Bug
- Revert autogen.sh
$ mv autogen.sh.bak autogen.sh
Bye, Reiner.
--
,,,
(o o)
---ooO-(_)-Ooo--- | PGP key available | http://rsteib.home.pages.de/
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2009-09-19 14:25 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-09-18 19:02 bug#4452: 23.1; sh-learn-buffer-indent unexpectedly displays *indent* buffer Chong Yidong
2009-09-19 14:25 ` Reiner Steib
-- strict thread matches above, loose matches on Subject: below --
2009-09-16 18:11 Reiner Steib
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.