GNU bug report logs -
#8053
shell-script mode <<EOF not case sensitive
Previous Next
Reported by: jidanni <at> jidanni.org
Date: Wed, 16 Feb 2011 12:23:02 UTC
Severity: normal
Done: Stefan Monnier <monnier <at> IRO.UMontreal.CA>
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 8053 in the body.
You can then email your comments to 8053 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org
:
bug#8053
; Package
emacs
.
(Wed, 16 Feb 2011 12:23:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
jidanni <at> jidanni.org
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Wed, 16 Feb 2011 12:23:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
$ cat m.sh
cat <<EOF
This line is inside the here doc
eof
So is this, but shell-script mode doesn't think so. Otherwise the color
would be the same.
EOF
$ emacs -Q m.sh
Information forwarded
to
owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org
:
bug#8053
; Package
emacs
.
(Thu, 17 Feb 2011 12:42:01 GMT)
Full text and
rfc822 format available.
Message #8 received at submit <at> debbugs.gnu.org (full text, mbox):
jidanni <at> jidanni.org wrote:
> $ cat m.sh
> cat <<EOF
> This line is inside the here doc
> eof
> So is this, but shell-script mode doesn't think so. Otherwise the color
> would be the same.
> EOF
> $ emacs -Q m.sh
case-fold-search should be bound to nil in
sh-syntax-propertize-here-doc
Here's a patch:
From f7731d08aeb4c72c85e91f1fb1d9b1ee1bc59856 Mon Sep 17 00:00:00 2001
From: Lawrence Mitchell <wence <at> gmx.li>
Date: Thu, 17 Feb 2011 12:48:29 +0000
Subject: [PATCH] Make search for end of here-doc case sensitive
* progmodes/sh-script.el (sh-syntax-propertize-here-doc): Bind
case-fold-search to nil when looking for end of here-doc.
---
lisp/ChangeLog | 5 +++++
lisp/progmodes/sh-script.el | 3 ++-
2 files changed, 7 insertions(+), 1 deletions(-)
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index c204b87..efbbfe1 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
+2011-02-17 Lawrence Mitchell <wence <at> gmx.li>
+
+ * progmodes/sh-script.el (sh-syntax-propertize-here-doc): Bind
+ case-fold-search to nil when looking for end of here-doc.
+
2011-02-09 Deniz Dogan <deniz.a.m.dogan <at> gmail.com>
* net/rcirc.el (rcirc-ctcp-sender-PING): Simplifying.
diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el
index d80d814..ecbac26 100644
--- a/lisp/progmodes/sh-script.el
+++ b/lisp/progmodes/sh-script.el
@@ -969,7 +969,8 @@ Point is at the beginning of the next line."
(defun sh-syntax-propertize-here-doc (end)
(let ((ppss (syntax-ppss)))
(when (eq t (nth 3 ppss))
- (let ((key (get-text-property (nth 8 ppss) 'sh-here-doc-marker)))
+ (let ((key (get-text-property (nth 8 ppss) 'sh-here-doc-marker))
+ (case-fold-search nil))
(when (re-search-forward
(concat "^\\([ \t]*\\)" (regexp-quote key) "\\(\n\\)")
end 'move)
--
Lawrence Mitchell <wence <at> gmx.li>
Reply sent
to
Stefan Monnier <monnier <at> IRO.UMontreal.CA>
:
You have taken responsibility.
(Fri, 18 Feb 2011 21:48:02 GMT)
Full text and
rfc822 format available.
Notification sent
to
jidanni <at> jidanni.org
:
bug acknowledged by developer.
(Fri, 18 Feb 2011 21:48:02 GMT)
Full text and
rfc822 format available.
Message #13 received at 8053-done <at> debbugs.gnu.org (full text, mbox):
> case-fold-search should be bound to nil in
> sh-syntax-propertize-here-doc
> Here's a patch:
Thanks, installed,
Stefan
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Sat, 19 Mar 2011 11:24:05 GMT)
Full text and
rfc822 format available.
This bug report was last modified 14 years and 116 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.