unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#5525: 23.1; In c-mode, C-M-h multiple times does nothing
@ 2010-02-04 21:03 Dani Moncayo
  2010-02-06 19:33 ` Glenn Morris
  2012-03-08 11:49 ` bug#5525: Bug #5525: " Alan Mackenzie
  0 siblings, 2 replies; 3+ messages in thread
From: Dani Moncayo @ 2010-02-04 21:03 UTC (permalink / raw)
  To: 5525

[-- Attachment #1: Type: text/plain, Size: 3584 bytes --]

I've tried the C-M-h command at the beginning of a very simple buffer in
c-mode.

The first time i use de command, the first "defun" is selected, but when i
repeat the command more times, nothing happens, but there are more defun's
after the first one!!

This is my c-mode buffer:

-------------------------
int f1()
{
  return 1;
}


int f2()
{
  return 1;
}
-------------------------

So, Why i can't select f2 when i run the C-M-h command several times in a
row?



In GNU Emacs 23.1.1 (x86_64-pc-linux-gnu, GTK+ Version 2.18.3)
 of 2009-11-10 on crested, modified by Debian
Windowing system distributor `The X.Org Foundation', version 11.0.10604000
configured using `configure  '--build=x86_64-linux-gnu'
'--host=x86_64-linux-gnu' '--prefix=/usr' '--sharedstatedir=/var/lib'
'--libexecdir=/usr/lib' '--localstatedir=/var/lib'
'--infodir=/usr/share/info' '--mandir=/usr/share/man' '--with-pop=yes'
'--enable-locallisppath=/etc/emacs23:/etc/emacs:/usr/local/share/emacs/23.1/site-lisp:/usr/local/share/emacs/site-lisp:/usr/share/emacs/23.1/site-lisp:/usr/share/emacs/site-lisp:/usr/share/emacs/23.1/leim'
'--with-x=yes' '--with-x-toolkit=gtk' '--with-toolkit-scroll-bars'
'build_alias=x86_64-linux-gnu' 'host_alias=x86_64-linux-gnu'
'CFLAGS=-DDEBIAN -g -O2' 'LDFLAGS=-g' 'CPPFLAGS=''

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: es_ES.UTF-8
  value of $XMODIFIERS: nil
  locale-coding-system: utf-8-unix
  default-enable-multibyte-characters: t

Major mode: C/l

Minor modes in effect:
  iswitchb-mode: t
  tooltip-mode: t
  mouse-wheel-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-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
  abbrev-mode: t

Recent input:
n M-h M-h M-h M-h C-p C-p C-p C-p C-p C-p C-p C-p C-p
C-p C-p C-g M-h M-h M-h M-h C-g C-h C-h C-h C-g C-g
C-g C-g M-h M-h M-h C-g C-n C-n C-n C-n C-n C-n C-n
C-n C-n C-n C-n C-n C-n C-n C-n C-n C-k C-x C-s C-p
C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p M-h M-h M-h
M-h C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p
C-g M-h M-h M-h M-h M-h C-g C-M-h C-M-h C-M-h C-M-h
C-M-h C-M-h C-M-h C-M-h C-M-h C-n C-n C-n C-n C-n C-n
C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-n C-g
s-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p
C-p C-p C-p C-p C-p C-p C-f C-f C-f C-f g e <backspace>
<backspace> f 1 C-d C-d C-d C-d C-d C-d C-d C-d C-d
C-n C-n C-n C-n C-n C-n C-b C-b C-f <backspace> f 2
C-d C-d C-d C-d C-d C-d C-d C-d C-x C-s C-n C-n C-n
C-n C-n C-n C-n C-n C-n C-n C-n C-n C-p C-p C-p C-a
C-k C-k C-k C-k C-k C-k C-k C-k C-k C-x C-s C-k C-k
C-k C-k C-k C-k C-k C-k C-k C-k C-k C-k C-k C-k C-k
C-k C-p C-p C-n C-e <return> <return> i = 4 N <backspace>
; <return> <return> r e t u r n SPC i ; C-x C-s C-p
C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p
C-p C-p C-p C-p C-p C-p C-p C-p C-p C-p C-M-h C-M-h
C-M-h C-M-h C-M-h C-M-h C-n C-n C-n C-g C-M-h C-M-h
C-M-h M-x r e p o r t SPC e m a SPC b u SPC <return>
C-c C M-x M-p <return>

Recent messages:
Saving file /home/dani/emacs/prueba.c...
Wrote /home/dani/emacs/prueba.c
Saving file /home/dani/emacs/prueba.c...
Wrote /home/dani/emacs/prueba.c
Saving file /home/dani/emacs/prueba.c...
Wrote /home/dani/emacs/prueba.c
Mark set [6 times]
Quit
Mark set [3 times]
/usr/bin/mail is not an executable.  Setting mail-interactive to t.
Quit

[-- Attachment #2: Type: text/html, Size: 4159 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#5525: 23.1; In c-mode, C-M-h multiple times does nothing
  2010-02-04 21:03 bug#5525: 23.1; In c-mode, C-M-h multiple times does nothing Dani Moncayo
@ 2010-02-06 19:33 ` Glenn Morris
  2012-03-08 11:49 ` bug#5525: Bug #5525: " Alan Mackenzie
  1 sibling, 0 replies; 3+ messages in thread
From: Glenn Morris @ 2010-02-06 19:33 UTC (permalink / raw)
  To: Dani Moncayo; +Cc: 5525

Dani Moncayo wrote:

> So, Why i can't select f2 when i run the C-M-h command several times
> in a row?

Because in c-mode, C-M-h doesn't run mark-defun, it runs C-mode's
version of mark-defun, which doesn't have the feature you describe.
I'm sure other modes are guilty of this too (eg the Fortran ones are).

This feature could be added to each mode's version, but the right
thing is probably to just leave C-M-h bound to the standard
mark-defun. Provided end-of-defun-function etc are set to the correct
mode-specific values, mark-defun ought to do the right thing in each
mode anyway.

But it probably isn't appropriate to change this for 23.2 at this
stage.






^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#5525: Bug #5525: In c-mode, C-M-h multiple times does nothing.
  2010-02-04 21:03 bug#5525: 23.1; In c-mode, C-M-h multiple times does nothing Dani Moncayo
  2010-02-06 19:33 ` Glenn Morris
@ 2012-03-08 11:49 ` Alan Mackenzie
  1 sibling, 0 replies; 3+ messages in thread
From: Alan Mackenzie @ 2012-03-08 11:49 UTC (permalink / raw)
  To: 5525-done

Fixed, revision #107534.





^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-03-08 11:49 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-02-04 21:03 bug#5525: 23.1; In c-mode, C-M-h multiple times does nothing Dani Moncayo
2010-02-06 19:33 ` Glenn Morris
2012-03-08 11:49 ` bug#5525: Bug #5525: " Alan Mackenzie

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).