1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2025-01-06 11:55:48 +00:00
Commit Graph

5448 Commits

Author SHA1 Message Date
Leo Liu
070ccca42d * progmodes/octave.el (octave-submit-bug-report): Obsolete.
(octave-mode, inferior-octave-mode): Use setq-local.
(octave-not-in-string-or-comment-p): Renamed to
octave-in-string-or-comment-p.
(octave-in-comment-p, octave-in-string-p)
(octave-in-string-or-comment-p): Replace defsubst with defun.
2013-04-26 12:16:37 +08:00
Leo Liu
584ea27747 * progmodes/octave.el (octave-completion-at-point-function): Make
use of inferior octave process.
(octave-initialize-completions): Remove.
(inferior-octave-completion-table): New function.
(inferior-octave-completion-at-point): Use it.
(octave-completion-alist): Remove.
2013-04-26 00:23:56 +08:00
Stefan Monnier
1693b06af5 * lisp/progmodes/opascal.el: Use font-lock and syntax-propertize.
(opascal-mode-syntax-table): New var.
(opascal-literal-kind, opascal-is-literal-end)
(opascal-literal-token-at): Rewrite.
(opascal--literal-start-re, opascal-font-lock-keywords)
(opascal--syntax-propertize): New constants.
(opascal-font-lock-defaults): Adjust.
(opascal-mode): Use them.  Set comment-<foo> variables as well.
(delphi-comment-face, opascal-comment-face, delphi-string-face)
(opascal-string-face, delphi-keyword-face, opascal-keyword-face)
(delphi-other-face, opascal-other-face): Remove face variables.
(opascal-save-state): Remove macro.
(opascal-fontifying-progress-step): Remove constant.
(opascal--ignore-changes): Remove var.
(opascal-set-token-property, opascal-parse-next-literal)
(opascal-is-stable-literal, opascal-complete-literal)
(opascal-is-literal-start, opascal-face-of)
(opascal-parse-region, opascal-parse-region-until-stable)
(opascal-fontify-region, opascal-after-change)
(opascal-debug-show-is-stable, opascal-debug-unparse-buffer)
(opascal-debug-parse-region, opascal-debug-parse-window)
(opascal-debug-parse-buffer, opascal-debug-fontify-window)
(opascal-debug-fontify-buffer): Remove.
(opascal-debug-mode-map): Adjust accordingly.
2013-04-25 12:07:33 -04:00
Leo Liu
be64c05d81 Merge octave-mod.el and octave-inf.el into octave.el with some
cleanups.

* progmodes/octave.el: New file renamed from octave-mod.el.
* progmodes/octave-inf.el: Merged into octave.el.
* progmodes/octave-mod.el: Renamed to octave.el.
2013-04-25 22:51:08 +08:00
Stefan Monnier
ced3fc5d2f * lisp/progmodes/octave-mod.el (octave-smie-forward-token): Only emit
semi-colons if the line is not otherwise empty.
* lisp/emacs-lisp/smie.el (smie-indent--hanging-p): Don't burp at EOB.
(smie-indent-keyword): Improve the check to ensure that the next
comment is really on the same line.
(smie-indent-comment): Don't align with a subsequent closer (or eob).

Fixes: debbugs:14218
2013-04-24 23:25:34 -04:00
Stefan Monnier
5058062aa4 * lisp/progmodes/opascal.el (opascal-set-token-property): Rename from
opascal-set-text-properties and only set `token'.
(opascal-literal-text-properties): Remove.
(opascal-parse-next-literal, opascal-debug-unparse-buffer):
Adjust callers.

Fixes: debbugs:14134
2013-04-24 16:44:45 -04:00
Magnus Henoch
4391916c58 * lisp/progmodes/compile.el (compilation-next-error-function):
Pass "formats" to compilation-find-file.

Fixes: debbugs:11777
2013-04-24 09:50:22 -04:00
Stefan Monnier
bcd7a0a4c5 Use add/remove-function to manipulate process-filters.
* lisp/emacs-lisp/nadvice.el (advice--where-alist): Add :override.
(remove-function): Autoload.

* lisp/comint.el (comint-redirect-original-filter-function): Remove.
(comint-redirect-cleanup, comint-redirect-send-command-to-process):
* lisp/vc/vc-cvs.el (vc-cvs-annotate-process-filter,vc-cvs-annotate-command):
* lisp/progmodes/octave-inf.el (inferior-octave-send-list-and-digest):
* lisp/progmodes/prolog.el (prolog-consult-compile):
* lisp/progmodes/gdb-mi.el (gdb, gdb--check-interpreter):
Use add/remove-function instead.
* lisp/progmodes/gud.el (gud-tooltip-original-filter): Remove.
(gud-tooltip-process-output, gud-tooltip-tips):
Use add/remove-function instead.
* lisp/progmodes/xscheme.el (xscheme-previous-process-state): Remove.
(scheme-interaction-mode, exit-scheme-interaction-mode):
Use add/remove-function instead.

* lisp/vc/vc-dispatcher.el: Use lexical-binding.
(vc--process-sentinel): Rename from vc-process-sentinel.
Change last arg to be the code to run.  Don't use vc-previous-sentinel
and vc-sentinel-commands any more.
(vc-exec-after): Allow code to be a function.  Use add/remove-function.
(compilation-error-regexp-alist, view-old-buffer-read-only): Declare.
2013-04-20 12:24:04 -04:00
Masatake YAMATO
4d3268ba39 * lisp/progmodes/sh-script.el (sh-imenu-generic-expression): Handle
function names with a single character.
2013-04-20 03:50:28 +09:00
Dima Kogan
863beb2713 * lisp/progmodes/gud.el (gud-perldb-marker-filter): Understand position info
for subroutines defined in an eval.

Fixes: debbugs:14182
2013-04-19 11:58:07 -04:00
Fabián Ezequiel Gallina
6bd1a072a8 Small fixes to 2013-04-19T02:31:09Z!fgallina@gnu.org
* lisp/ChangeLog: Fix Changelog Entry.

* progmodes/python.el (python-imenu-create-flat-index): Remove
  leftover `message' call and give credit to old
  imenu--flatten-index-alist.
2013-04-19 10:29:41 -03:00
Fabián Ezequiel Gallina
adc3121366 New faster Imenu implementation.
* lisp/progmodes/python.el:
(python-imenu-prev-index-position):
(python-imenu-format-item-label-function)
(python-imenu-format-parent-item-label-function)
(python-imenu-format-parent-item-jump-label-function):
New vars.
(python-imenu-format-item-label)
(python-imenu-format-parent-item-label)
(python-imenu-format-parent-item-jump-label)
(python-imenu--put-parent, python-imenu--build-tree)
(python-imenu-create-index, python-imenu-create-flat-index)
(python-util-popn): New functions.
(python-mode): Set imenu-create-index-function to
python-imenu-create-index.

* test/automated/python-tests.el (python-imenu-prev-index-position-1):
Removed test.
(python-imenu-create-index-1, python-imenu-create-flat-index-1):
New tests.

Fixes: debbugs:14058
2013-04-18 23:31:09 -03:00
Fabián Ezequiel Gallina
04754d3612 * lisp/progmodes/python.el (python-nav--syntactically): Fix cornercases
and do not care about match data.

* test/automated/python-tests.el (python-nav-backward-defun-2)
(python-nav-backward-defun-3, python-nav-forward-defun-2)
(python-nav-forward-defun-3): New tests.
2013-04-17 19:23:13 -03:00
Fabián Ezequiel Gallina
083850a6a1 New defun movement commands.
* lisp/progmodes/python.el (python-nav--syntactically)
(python-nav--forward-defun, python-nav-backward-defun)
(python-nav-forward-defun): New functions.

* test/automated/python-tests.el (python-nav-backward-defun-1)
(python-nav-forward-defun-1): New tests.
2013-04-17 02:08:20 -03:00
Fabián Ezequiel Gallina
619ed6e18a * progmodes/python.el (python-syntax--context-compiler-macro): New defun.
(python-syntax-context): Use named compiler-macro for backwards
compatibility with Emacs 24.x.
2013-04-16 23:52:50 -03:00
Leo Liu
ad64b83d9b Fix last change 2013-04-17 09:49:22 +08:00
Leo Liu
7a1beb6cf1 * progmodes/octave-mod.el (octave-mode-map): Fix key binding to
octave-hide-process-buffer.
2013-04-17 09:46:26 +08:00
Jean-Philippe Gravel
7ce5be5461 * lisp/progmodes/gdb-mi.el (gdbmi-bnf-incomplete-record-result):
Fix adjustment of offset when receiving incomplete responses from GDB.

Fixes: debbugs:14129
2013-04-16 20:35:22 -04:00
Stefan Monnier
351edece98 * lisp/progmodes/python.el (python-mode-skeleton-abbrev-table): Rename from
python-mode-abbrev-table.
(python-skeleton-define): Adjust accordingly.
(python-mode-abbrev-table): New table that inherits from it so that
python-skeleton-autoinsert does not affect non-skeleton abbrevs.
* lisp/abbrev.el (abbrev--symbol): New function, extracted from abbrev-symbol.
(abbrev-symbol): Use it.
(abbrev--before-point): Use it since we already handle inheritance.
2013-04-16 13:28:11 -04:00
Leo Liu
613f948181 * progmodes/octave-mod.el (octave-mode-map): Remove redundant key
binding to info-lookup-symbol.
2013-04-17 00:38:31 +08:00
Dmitry Gutov
fb549d640a * lisp/progmodes/ruby-mode.el (ruby-beginning-of-defun)
(ruby-end-of-defun, ruby-move-to-block): Bind `case-fold-search'
to nil.
(ruby-end-of-defun): Remove the unused arg, change the docstring
to reflect that this function is only used as the value of
`end-of-defun-function'.
(ruby-beginning-of-defun): Remove "top-level" from the docstring,
to reflect an earlier change that beginning/end-of-defun functions
jump between methods in a class definition, as well as top-level
functions.
2013-04-16 03:07:14 +04:00
Alan Mackenzie
20e527d0c5 Correct the placement of c-cpp-delimiters when there're #s not at col 0.
* progmodes/cc-langs.el (c-anchored-cpp-prefix): Reformulate and
        place a submatch around the #.
        * progmodes/cc-mode.el(c-neutralize-syntax-in-and-mark-CPP): Start
        a search at BOL.  Put the c-cpp-delimiter category text propertiy
        on the #, not BOL.
2013-04-15 16:10:24 +00:00
Alan Mackenzie
85c9ab6469 Reformulate java imenu-generic-expression.
The old expression contained ill formed regexps.

        * progmodes/cc-menus.el (cc-imenu-java-ellipsis-regexp)
        (cc-imenu-java-type-spec-regexp, cc-imenu-java-comment-regexp)
        (cc-imenu-java-method-arg-regexp): New defconsts.
        (cc-imenu-java-build-type-args-regex): New defun.
        (cc-imenu-java-generic-expression): Fixed, to remove "ambiguous"
        handling of spaces in the regexp.
2013-04-15 14:32:20 +00:00
Masatake YAMATO
7144c62778 * lisp/progmodes/sh-script.el: Implement `sh-mode' own
`add-log-current-defun-function'.
(sh-current-defun-name): New function.
(sh-mode): Use the function.

Fixes: debbugs:14112
2013-04-10 02:31:17 +09:00
Alan Mackenzie
691e26ae7d Handle `parse-partial-sexp' landing inside a comment opener
(Bug#13244). Also adapt to the new values of element 7 of a parse
	state.

	* progmodes/cc-engine.el (c-state-pp-to-literal): New optional
	parameter `not-in-delimiter'.  Handle being inside comment opener.
	(c-invalidate-state-cache-1): Reckon with an extra "invalid"
	character in case we're typing a '*' after a '/'.
	(c-literal-limits): Handle the awkward "not-in-delimiter" cond arm
	instead by passing the parameter to c-state-pp-to-literal.

	* progmodes/cc-fonts.el (c-font-lock-doc-comments): New handling
	for elt. 7 of a parse state.
2013-04-03 17:50:39 +00:00
Glenn Morris
8d3655be5a Merge from emacs-24; up to 2012-12-26T16:22:18Z!michael.albinus@gmx.de 2013-03-30 09:55:47 -07:00
Ted Zlatanov
0b93819010 Move forward-whitespace, forward-symbol, forward-same-syntax commands to subr.el. Use forward-symbol in supermode.el again.
* subr.el (forward-whitespace, forward-symbol)
(forward-same-syntax): Move from thingatpt.el.

* progmodes/subword.el: Back to using `forward-symbol'.
2013-03-29 21:32:12 -04:00
Ted Zlatanov
75a2f98113 * progmodes/subword.el (superword-mode): Use forward-sexp' instead of forward-symbol'. 2013-03-29 09:24:19 -04:00
Ted Zlatanov
002668e109 Add `superword-mode' 2013-03-27 10:04:34 -04:00
Fabián Ezequiel Gallina
c9886b39eb Un-indent after "pass" and "return" statements
* lisp/progmodes/python.el (python-indent-block-enders): New var.
(python-indent-calculate-indentation): Use it.

* test/automated/python-tests.el
(python-indent-block-enders): New test.
(python-info-current-defun-2): Fix test.

Fixes: debbugs:13888
2013-03-25 22:55:11 -03:00
Ted Zlatanov
9bb0d8227e * progmodes/cfengine.el: Use symbol motion commands instead of extending the word syntax. 2013-03-22 15:06:53 -04:00
Ted Zlatanov
aa70364092 * progmodes/cfengine.el (cfengine-common-syntax): Add "_" to word syntax. 2013-03-21 12:11:13 -04:00
Leo Liu
50c3a20bac * progmodes/compile.el (compilation-display-error): New command.
(compilation-mode-map, compilation-minor-mode-map): Bind it to
C-o.

Fixes: debbugs:13992
2013-03-19 08:16:14 +08:00
Stefan Monnier
78be8b6465 Merge from emacs-24 2013-03-16 18:08:22 -04:00
Leo Liu
67ed8fcd04 * progmodes/scheme.el: Add indentation and font-locking for λ.
Fixes: debbugs:13975
2013-03-16 23:24:39 +08:00
Ted Zlatanov
ca68a22e64 * progmodes/cfengine.el: add CFEngine 3-specific indentation. 2013-03-12 11:49:26 -04:00
Stefan Monnier
940e509914 Use locate-user-emacs-file.
* lisp/type-break.el (type-break-file-name):
* lisp/textmodes/remember.el (remember-data-file):
* lisp/strokes.el (strokes-file):
* lisp/shadowfile.el (shadow-initialize):
* lisp/saveplace.el (save-place-file):
* lisp/ps-bdf.el (bdf-cache-file):
* lisp/progmodes/idlwave.el (idlwave-config-directory):
* lisp/net/quickurl.el (quickurl-url-file):
* lisp/international/kkc.el (kkc-init-file-name):
* lisp/ido.el (ido-save-directory-list-file):
* lisp/emulation/viper.el (viper-custom-file-name):
* lisp/emulation/vip.el (vip-startup-file):
* lisp/calendar/todo-mode.el (todo-file-do, todo-file-done, todo-file-top):
* lisp/calendar/timeclock.el (timeclock-file): Use locate-user-emacs-file.
2013-03-11 22:08:21 -04:00
Ted Zlatanov
526cb962b5 * progmodes/cfengine.el: Update for CFEngine 3.4.2 and higher. 2013-03-11 13:17:13 -04:00
Jean-Philippe Gravel
6ff2c8f1fe * lisp/progmodes/gdb-mi.el: Speed up initialization. Use lexical-binding.
Fix up docstring according to conventions.
(gdbmi-debug-mode): New var.
(gdbmi-start-with, gdbmi-same-start, gdbmi-is-number, gdbmi-bnf-init)
(gdbmi-bnf-output, gdbmi-bnf-skip-unrecognized, gdbmi-bnf-gdb-prompt)
(gdbmi-bnf-result-record, gdbmi-bnf-out-of-band-record)
(gdbmi-bnf-async-record, gdbmi-bnf-stream-record)
(gdbmi-bnf-console-stream-output, gdbmi-bnf-target-stream-output)
(gdbmi-bnf-log-stream-output, gdbmi-bnf-result-and-async-record-impl)
(gdbmi-bnf-incomplete-record-result): New functions.
(gdb-car<): Remove function.
(gdbmi-record-list): Remove variable.
(gdbmi-bnf-state, gdbmi-bnf-offset): New vars.
(gdbmi-bnf-result-state-configs): New const.
(gud-gdbmi-marker-filter): Rewrite.
(gdb-ignored-notification, gdb-thread-created, gdb-thread-exited)
(gdb-thread-selected, gdb-running, gdb-starting, gdb-stopped):
Add `token' argument.
(gdb-done, gdb-error): New functions.
(gdb-done-or-error): Add `is-complete' argument.  Change arg order.

Fixes: debbugs:10580
2013-03-11 13:13:39 -04:00
Michael Mauger
e18e61cf27 * progmodes/sql.el Version 3.2
Please note that my address changed to <michael@mauger.com>; the
<mmaug@yahoo.com> address remains active.
(sql-connection-alist): Updates documentation to fix bug#13715.
(sql-connect): Handle missing `sql-connection-alist' correctly.
(sql-mode-oracle-font-lock-keywords): Add missing keywords.
(sql-magic-go, sql-magic-semicolon): Mark with `delete-selection'
property.
(sql-default-value): New function.
(sql-get-login-ext, sql-get-login): Fixes bug where buffer-local
values were not used.
(sql-rename-buffer): Make sure alternate buffer name has no text
properties.
(sql-input-sender, sql-execute-feature): Fetch variable with
`buffer-local-value' rather than `with-current-buffer'.
(sql-*): Use #' function syntax consistently.
(sql-*): Use message/error/user-error consistently.
2013-03-11 00:09:37 -04:00
Dmitry Gutov
94e48c7d75 * lisp/progmodes/js.el (js--multi-line-declaration-indentation): Merge
from js2-mode (https://github.com/mooz/js2-mode/issues/89).
2013-03-07 20:08:33 +04:00
Dmitry Gutov
ab89e9f9a5 * lisp/progmodes/ruby-mode.el (ruby-syntax-propertize-function): Only
propertize regexp when not inside a string.

Fixes: debbugs:13885
2013-03-06 22:56:29 +04:00
Alan Mackenzie
33d1e2f5bd Correct the position of point in some line-up functions.
progmodes/cc-align.el (c-lineup-whitesmith-in-block, c-lineup-assignments)
(c-lineup-gcc-asm-reg ): take position of point at column 0 rather than
at a random place in the line.
doc/misc/cc-mode.texi (Custom Line-Up): State explicitly that point
starts at a random position in the line being indented.
2013-03-06 14:24:39 +00:00
Paul Eggert
c38e0c974e Prefer UTF-8 when the encoding shouldn't matter and changes are small. 2013-03-05 09:13:01 -08:00
Alan Mackenzie
e0bc0f33bd Replace last-command-event' by last-command-char' in XEmacs.
progmodes/cc-defs.el (c-last-command-char): New macro.
progmodes/cc-align.el (c-semi&comma-inside-parenlist)
(c-semi&comma-no-newlines-before-nonblanks)
(c-semi&comma-no-newlines-for-oneline-inliners): Use the new macro in
place of `last-command-event'.
progmodes/cc-cmds.el (c-electric-pound, c-electric-brace)
(c-electric-slash, c-electric-semi&comma, c-electric-lt-gt)
(c-electric-paren, c-electric-continued-statement): Use the new macro in
place of `last-command-event'.
2013-03-04 19:33:23 +00:00
Peter Kleiweg
2ae3d73667 Update ps-mode.el from upstream
* lisp/progmodes/ps-mode.el (ps-mode-version): Bump to 1.1i.
(ps-mode-octal-region): Use string-make-unibyte.
2013-02-23 14:06:45 -08:00
Glenn Morris
e8ba235206 Add bug-gnu-emacs to some specialized bug report addresses
* emulation/viper-cmd.el (viper-submit-report):
* progmodes/ps-mode.el (ps-mode-maintainer-address):
* progmodes/vera-mode.el (vera-mode-help-address):
* textmodes/artist.el (artist-maintainer-address):
* textmodes/reftex.el (reftex-report-bug):
* vc/ediff-util.el (ediff-submit-report):
Add bug-gnu-emacs to bug report address.
2013-02-23 13:54:00 -08:00
Glenn Morris
3296c4430f Make simula.el special bug reporting obsolete
* progmodes/simula.el (simula-mode-menu, simula-mode-map):
Remove bug report entries.
(simula-mode-help-address, simula-submit-bug-report): Make obsolete.
2013-02-23 13:49:41 -08:00
Glenn Morris
f4146d9896 Doc fixes re set-variable
* lisp/cmuscheme.el (scheme-buffer):
* lisp/progmodes/inf-lisp.el (inferior-lisp-buffer):
* lisp/progmodes/tcl.el (inferior-tcl-buffer):
* lisp/textmodes/tex-mode.el (tex-command): Doc fixes.
2013-02-21 20:59:28 -05:00
Glenn Morris
cfbf790d80 Merge from emacs-24; up to 2012-12-21T07:35:02Z!ueno@gnu.org 2013-02-21 08:56:49 -08:00