GNU bug report logs - #27192
25.2; c-mode narrow-to-region broken

Previous Next

Packages: emacs, cc-mode;

Reported by: Gordon Ross <gordon.w.ross <at> gmail.com>

Date: Fri, 2 Jun 2017 03:02:01 UTC

Severity: normal

Tags: moreinfo, wontfix

Found in version 25.2

Done: Glenn Morris <rgm <at> gnu.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 27192 in the body.
You can then email your comments to 27192 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#27192; Package emacs. (Fri, 02 Jun 2017 03:02:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Gordon Ross <gordon.w.ross <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Fri, 02 Jun 2017 03:02:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Gordon Ross <gordon.w.ross <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: 25.2; c-mode narrow-to-region broken
Date: Thu, 1 Jun 2017 21:17:16 -0400
I often use "narrow-to-region" in c-mode when I want to do something
like replace-string but just within the bounds of one C function or
(in the example represented in this bug report) the entirety of one
switch statement starting with switch (expr) { ... ending with }

After my recent upgrade to emacs 25.2, the TAB "auto-indent" feature
usually doesn't work in such a narrowed region, briefly showing
complaints in the minibuffer (See "Args out of range" in messages
section below) and not indenting.



In GNU Emacs 25.2.1 (i386-pc-solaris2.11, GTK+ Version 2.24.30)
 of 2017-04-25 built on hipster.openindiana.org
Windowing system distributor 'Project OpenIndiana', version 11.0.11804000
Configured using:
 'configure CC=/usr/gcc/4.9/bin/gcc CXX=/usr/gcc/4.9/bin/g++
 F77=/usr/gcc/4.9/bin/gfortran FC=/usr/gcc/4.9/bin/gfortran 'CFLAGS=-m32
 -O3 ' 'CXXFLAGS= -m32' 'FFLAGS= -m32' FCFLAGS=-m32 'LDFLAGS=-m32
 -L/usr/gnu/lib -R/usr/gnu/lib'
 PKG_CONFIG_PATH=/usr/lib/pkgconfig/gnutls-3:/usr/lib/pkgconfig
 --prefix=/usr --mandir=/usr/share/man --bindir=/usr/bin
 --libdir=/usr/lib --sbindir=/usr/sbin --infodir=/usr/share/info
 --with-compress-info=no --datarootdir=/usr/share --libexecdir=/usr/lib
 --with-gif=no ac_cv_sys_long_file_names=yes --with-x-toolkit=gtk2'

Configured features:
XPM JPEG TIFF PNG RSVG IMAGEMAGICK DBUS GCONF GSETTINGS NOTIFY ACL
GNUTLS LIBXML2 FREETYPE XFT ZLIB TOOLKIT_SCROLL_BARS GTK2 X11

Important settings:
  value of $LC_ALL: C
  value of $LC_COLLATE: C
  value of $LC_CTYPE: C
  value of $LC_MESSAGES: C
  value of $LC_MONETARY: C
  value of $LC_NUMERIC: C
  value of $LC_TIME: C
  value of $LANG: C
  locale-coding-system: nil

Major mode: C/l

Minor modes in effect:
  diff-auto-refine-mode: t
  tooltip-mode: t
  global-eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  blink-cursor-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 messages:
Quit
Auto-saving...done
Saving file foo.c...
Wrote foo.c
Making completion list...
Mark set
Quit
c-determine-limit: Args out of range: #<buffer smb_cmn_oplock.c>, 15565, 17393
Quit
Type C-x 1 to remove help window.
scroll-down-command: Beginning of buffer
You can run the command ‘emacs-version’ with M-x em-v RET
GNU Emacs 25.2.1 (i386-pc-solaris2.11, GTK+ Version 2.24.30) of 2017-04-25

Load-path shadows:
None found.

Features:
(shadow sort mail-extr emacsbug message idna format-spec rfc822 mml
mml-sec password-cache epg epg-config gnus-util mm-decode mm-bodies
mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail
rfc2047 rfc2045 ietf-drums mm-util help-fns help-mode mail-prsvr
mail-utils misearch multi-isearch compare-w vc-git diff-mode easy-mmode
cc-mode cc-fonts easymenu cc-guess cc-menus cc-cmds dired ls-lisp
cc-styles cc-align cc-engine cc-vars cc-defs cl-loaddefs pcase cl-lib
time-date mule-util tooltip eldoc electric uniquify ediff-hook vc-hooks
lisp-float-type mwheel x-win term/common-win x-dnd tool-bar dnd fontset
image regexp-opt fringe tabulated-list newcomment elisp-mode lisp-mode
prog-mode register page menu-bar rfn-eshadow timer select scroll-bar
mouse jit-lock font-lock syntax facemenu font-core frame cl-generic cham
georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao
korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech
european ethiopic indian cyrillic chinese charscript case-table epa-hook
jka-cmpr-hook help simple abbrev minibuffer cl-preloaded nadvice
loaddefs button faces cus-face macroexp files text-properties overlay
sha1 md5 base64 format env code-pages mule custom widget
hashtable-print-readable backquote dbusbind gfilenotify dynamic-setting
system-font-setting font-render-setting move-toolbar gtk x-toolkit x
multi-tty make-network-process emacs)

Memory information:
((conses 8 129503 30266)
 (symbols 24 22533 0)
 (miscs 20 185 1142)
 (strings 16 23076 7101)
 (string-bytes 1 879457)
 (vectors 8 18343)
 (vector-slots 4 910844 5292)
 (floats 8 181 421)
 (intervals 28 3452 1741)
 (buffers 520 27))




Information forwarded to bug-gnu-emacs <at> gnu.org, bug-cc-mode <at> gnu.org:
bug#27192; Package emacs,cc-mode. (Fri, 02 Jun 2017 06:32:01 GMT) Full text and rfc822 format available.

Message #8 received at 27192 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Gordon Ross <gordon.w.ross <at> gmail.com>
Cc: 27192 <at> debbugs.gnu.org
Subject: Re: bug#27192: 25.2; c-mode narrow-to-region broken
Date: Fri, 02 Jun 2017 09:31:58 +0300
> From: Gordon Ross <gordon.w.ross <at> gmail.com>
> Date: Thu, 1 Jun 2017 21:17:16 -0400
> 
> I often use "narrow-to-region" in c-mode when I want to do something
> like replace-string but just within the bounds of one C function or
> (in the example represented in this bug report) the entirety of one
> switch statement starting with switch (expr) { ... ending with }
> 
> After my recent upgrade to emacs 25.2, the TAB "auto-indent" feature
> usually doesn't work in such a narrowed region, briefly showing
> complaints in the minibuffer (See "Args out of range" in messages
> section below) and not indenting.

Please show an example of a buffer where this happens, and tell to
which part to narrow it in order to reproduce the problem.

Thanks.




Added tag(s) moreinfo. Request was from npostavs <at> users.sourceforge.net to control <at> debbugs.gnu.org. (Sat, 10 Jun 2017 12:55:02 GMT) Full text and rfc822 format available.

Added tag(s) wontfix. Request was from Glenn Morris <rgm <at> gnu.org> to control <at> debbugs.gnu.org. (Tue, 08 Jan 2019 20:50:03 GMT) Full text and rfc822 format available.

bug closed, send any further explanations to 27192 <at> debbugs.gnu.org and Gordon Ross <gordon.w.ross <at> gmail.com> Request was from Glenn Morris <rgm <at> gnu.org> to control <at> debbugs.gnu.org. (Tue, 08 Jan 2019 20:50:03 GMT) Full text and rfc822 format available.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 06 Feb 2019 12:24:19 GMT) Full text and rfc822 format available.

This bug report was last modified 6 years and 137 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.