GNU bug report logs -
#14402
f90-mode broken in multiple ways by trunk r112519
Previous Next
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
Your bug report
#14402: f90-mode broken in multiple ways by trunk r112519
which was filed against the emacs package, has been closed.
The explanation is attached below, along with your original report.
If you require more details, please reply to 14402 <at> debbugs.gnu.org.
--
14402: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=14402
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
>> C-x C-f foo.f90 RET
>> program foo
>> end<TAB>
>> it should complete in "end program foo" instead it stays to "end".
>> "end" is only indented,
I just installed the patch below which seems to fix this.
> This is all breakage from r112519.
> Specifically, f90-looking-at-program-block-end is broken (and who knows
> what else).
Interestingly, the bug was caused by the fact that the old code relied
on a bug in the handling of the \> regexp: more specifically \> treated
(string-match "ab\\>?" foo) as (string-match "a\\(?:b\\>\\)?" foo)
instead of the expected (string-match "ab\\(?:\\>\\)?" foo).
Stefan
=== modified file 'lisp/progmodes/f90.el'
--- lisp/progmodes/f90.el 2013-05-14 19:29:35 +0000
+++ lisp/progmodes/f90.el 2013-05-15 00:40:06 +0000
@@ -842,14 +842,14 @@
;; Regexps for finding program structures.
(defconst f90-blocks-re
- (concat "\\(block[ \t]*data\\|"
+ (concat "\\(\\(?:block[ \t]*data\\|"
(regexp-opt '("do" "if" "interface" "function" "module" "program"
"select" "subroutine" "type" "where" "forall"
;; F2003.
"enum" "associate"
;; F2008.
"submodule" "block" "critical"))
- "\\)\\_>")
+ "\\)\\_>\\)")
"Regexp potentially indicating a \"block\" of F90 code.")
(defconst f90-program-block-re
[Message part 3 (message/rfc822, inline)]
The trunk revision #112579 shows an issue *very* similar to that
described in bug #9199 [*]: same way to reproduce it, same result.
In my ~/.emacs.d/init.el I have something like this:
;; c-mode
(add-hook 'c-mode-hook
'(lambda()
;; No indent for open bracket
(c-set-offset 'substatement-open 0)
;; Add index of func. to menu bar
(imenu-add-to-menubar "Functions")
)
)
[...]
;; f90-mode
(add-hook 'f90-mode-hook
'(lambda()
;; Add index of func. to menu bar
(imenu-add-to-menubar "Program-Units")
)
)
[...]
(setq imenu-auto-rescan t)
(setq imenu-auto-rescan-maxout 500000)
[...]
This time the issue shows up also in other programming modes. The Emacs
buffer displays this error message:
Error in menu-bar-update-hook (imenu-update-menubar):
(wrong-type-argument stringp ("Types" f90-imenu-type-matcher 1))
This issue is not shown by rev. 112494 I have build on May 07, 2013.
Ciao,
Angelo.
---
[*] http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9199
This bug report was last modified 12 years and 68 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.