1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-12-01 08:17:38 +00:00
Commit Graph

547 Commits

Author SHA1 Message Date
Kenichi Handa
0f01f02fe7 decoder-tests.el (decoder-tests-prefer-utf-8-read):
Use with-ccoding-priority to avoid side-effect (Bug#14781).
2013-07-08 20:51:55 +09:00
Michael Albinus
84b6d3df1a * automated/file-notify-tests.el
(file-notify-test-remote-temporary-file-directory): Use
`null-device' on w32.
(file-notify--test-tmpfile, file-notify--test-tmpfile1)
(file-notify--test-results, file-notify--test-event)
(file-notify--deftest-remote, file-notify--event-test)
(file-notify--test-event-handler)
(file-notify--test-make-temp-name): Renamed, in order to mark them
internal.
(tramp-message-show-message, tramp-read-passwd): Tweak them for
better fitting in noninteractive tests.
(file-notify-test00-availability): Renamed from `file-notify-test0'.
(file-notify-test01-add-watch): Renamed from `file-notify-test1'.
Use `temporary-file-directory '.
(file-notify-test01-add-watch-remote): New test.
(file-notify-test02-events): Renamed from `file-notify-test2'.
(file-notify-test02-events-remote): Renamed from `file-notify-test3'.
(file-notify-test03-autorevert): Renamed from
`file-notify-test4'.  Use timeouts.
(file-notify-test03-autorevert-remote): Renamed from
`file-notify-test5'.
2013-07-05 16:06:14 +02:00
Michael Albinus
46e4f8217a * automated/file-notify-tests.el: New package. 2013-07-04 11:43:17 +02:00
Dmitry Gutov
3086ca2e2c * lisp/progmodes/ruby-mode.el (ruby-move-to-block): When we're at a
middle of block statement initially, lower the depth.  Remove
FIXME comment, not longer valid.  Remove middle of block statement
detection, no need to do that anymore since we've been using
`ruby-parse-region' here.
2013-07-03 05:02:18 +04:00
Paul Eggert
adc5dbceb0 Spelling fixes. 2013-06-30 08:10:33 -07:00
Dmitry Gutov
6dbafa3000 * lisp/progmodes/ruby-mode.el (ruby-syntax-propertize-function): Don't
start heredoc inside a string or comment.
2013-06-30 06:23:10 +04:00
Kenichi Handa
2ed909207e merge trunk 2013-06-29 12:31:15 +09:00
Kenichi Handa
3e3da66030 decoder-tests.el (decoder-tests-gen-file): New arg FILE.
(decoder-tests-ao-gen-file): Renamed from decoder-tests-filename.
Callers changed.
(decoder-tests-filename): New function.
(decoder-tests-prefer-utf-8-read)
(decoder-tests-prefer-utf-8-write): New function.
(ert-test-decoder-prefer-utf-8): New test.
2013-06-28 23:39:40 +09:00
Glenn Morris
9c8d35d532 Add Copyright header, standardize license notice 2013-06-27 09:14:05 -07:00
Dmitry Gutov
79f38c4eee * test/automated/package-x-test.el: Change the commentary.
(package-x-test--single-archive-entry-1-3)
(package-x-test--single-archive-entry-1-4): Fix the tests, by
using the appropriate data structure.
2013-06-27 13:51:55 +04:00
Dmitry Gutov
10a2da6ea4 * test/automated/package-x-test.el: Change the commentary. 2013-06-27 13:30:37 +04:00
Dmitry Gutov
9ea5cf9fbd * automated/Makefile.in (setwins): Include the 'data' subdirectory.
* automated/package-x-test.el: New file.

* automated/package-test.el: New file.

* automated/data/package: New directory, with test examples.

* lisp/emacs-lisp/package-x.el (package-upload-buffer-internal): Adapt
to `package-desc-version' being a list.  Use
`package--ac-desc-version' to retrieve version from a package
archive element.
2013-06-27 13:26:54 +04:00
Glenn Morris
df86ba7d4d * python-tests.el (python-tests-with-temp-file): Clean up after ourself 2013-06-26 22:46:51 -07:00
Glenn Morris
568a53f290 Fix ChangeLog typo 2013-06-26 19:16:53 -07:00
Glenn Morris
fc3ec98234 * automated/undo-tests.el (undo-test3): Remove test that seems to
nothing that the previous one doesn't, except leave a tempfile.

Fix copyright header.
2013-06-26 19:00:54 -07:00
Glenn Morris
f2136e1e28 info-xref.el: Update for Texinfo 5 change in *note format
* lisp/info-xref.el (info-xref-node-re, info-xref-note-re): New constants.
(info-xref-check-buffer): Use info-xref-note-re.

* test/automated/info-xref.el: New file.
2013-06-25 18:52:09 -07:00
Glenn Morris
51f853872f * test/automated/occur-tests.el (occur-test-create): New function.
Use it to create separate tests for each element, so we run them
all rather than stopping at the first error.
2013-06-24 19:24:32 -07:00
Glenn Morris
e31106e80a * test/automated/occur-tests.el (occur-tests):
Update for 2013-05-29 change to occur header line.
2013-06-24 19:52:33 -04:00
Eduard Wiebe
c5b0993e5f Extend flymake's warning predicate to be a function. Test suite for flymake.
* lisp/progmodes/flymake.el (flymake-warning-predicate): New.
(flymake-parse-line): Use it.
(flymake-warning-re): Make obsolete alias to
`flymake-warning-predicate'.
* doc/misc/flymake.texi (Parsing the output, Customizable variables):
Add reference to `flymake-warning-predicate'.
* test/automated/flymake-tests.el:
* test/automated/flymake/warnpred/Makefile
* test/automated/flymake/warnpred/test.c
* test/automated/flymake/warnpred/test.pl: New files.

Fixes: debbugs:14217
2013-06-21 10:36:13 -04:00
Juanma Barranquero
4f40506961 Fix typos in ChangeLogs. 2013-06-19 22:10:57 +02:00
Dmitry Gutov
d1bbba4fa5 * lisp/progmodes/ruby-mode.el (ruby-syntax-before-regexp-re):
Distinguish ternary operator tokens from slash symbol and slash
char literal.
2013-06-19 02:17:56 +04:00
Tassilo Horn
02a87775d4 * automated/reftex-tests.el (reftex-parse-from-file-test): Fix
test.
2013-06-12 16:43:46 +02:00
Tassilo Horn
18d78c5ed3 * automated/reftex-tests.el: New test suite for reftex. 2013-06-12 14:49:25 +02:00
Dmitry Gutov
973d1e126c * lisp/progmodes/ruby-mode.el (ruby-syntax-expansion-allowed-p):
Highlight expansions inside regexp literals.
2013-05-31 20:55:03 +04:00
Dmitry Gutov
19bb8e6293 * lisp/progmodes/ruby-mode.el (ruby-syntax-expansion-allowed-p): New
function, checks if expression expansion is allowed in given parse
state.
(ruby-syntax-propertize-expansion): Use it.
(ruby-syntax-propertize-function): Bind `case-fold-search' to nil
around the body.

* test/automated/ruby-mode-tests.el: New tests, for percent literals
and expression expansion.
2013-05-31 10:04:33 +04:00
Leo Liu
f236dd8432 * lisp/emacs-lisp/smie.el (smie-highlight-matching-block): Always turn
off the highlight first.

* lisp/progmodes/octave.el (octave-indent-comment): Tweak regexps.
(octave-help): Small simplification.

* test/indent/octave.m: Tweak.
2013-05-29 14:50:48 +08:00
Aidan Gauland
797c9e3df2 Rewrite Eshell tests using ERT 2013-05-26 19:54:01 +12:00
Leo Liu
cce6beebb7 * indent/octave.m: Add tests for %!, # and ### comments 2013-05-25 10:03:03 +08:00
Stefan Monnier
650cff3d87 * lisp/emacs-lisp/smie.el (smie-auto-fill): Rework to be more robust.
(smie-setup): Use add-function to set it.

* lisp/progmodes/octave.el (octave-smie-rules): Return nil rather than
0 after a semi-colon; it works better for smie-auto-fill.
(octave--indent-new-comment-line): New function.
(octave-indent-new-comment-line): Use it (indirectly).
(octave-mode): Don't disable smie-auto-fill.  Use add-function to
modify comment-line-break-function.
2013-05-24 15:37:55 -04:00
Kenichi Handa
bc9a50032c test/automated/decoder-tests.el: New file 2013-05-23 20:18:43 +09:00
Dmitry Gutov
1a0a0a8a6a * lisp/progmodes/ruby-mode.el (ruby-expression-expansion-re): Allow to
start at point, so that expansion starting right after opening
slash in a regexp is recognized.
(ruby-syntax-before-regexp-re): New defvar, extracted from
ruby-syntax-propertize-function.  Since the value of this regexp
is looked up at runtime now, we should be able to turn
`ruby-syntax-methods-before-regexp' into a defcustom later.
(ruby-syntax-propertize-function): Split regexp matching into two
parts, for opening and closing slashes.  That allows us to skip
over string interpolations and support multiline regexps.
Don't call `ruby-syntax-propertize-expansions', instead use another rule
for them, which calls `ruby-syntax-propertize-expansion'.
(ruby-syntax-propertize-expansions): Move `remove-text-properties'
call to `ruby-syntax-propertize-function'.
(ruby-syntax-propertize-expansion): Extracted from
`ruby-syntax-propertize-expansions'.  Handles one expansion.
(ruby-syntax-propertize-heredoc): Explicitly call
`ruby-syntax-propertize-expansions'.
(ruby-syntax-propertize-percent-literal): Leave point right after
the percent symbol, so that the expression expansion rule can
propertize the contents.

* test/automated/ruby-mode-tests.el (ruby-heredoc-highlights-interpolations)
(ruby-regexp-skips-over-interpolation)
(ruby-regexp-continues-till-end-when-unclosed)
(ruby-regexp-can-be-multiline)
(ruby-interpolation-inside-percent-literal): New tests.

* test/indent/ruby.rb: Add multiline regexp example.
2013-05-19 10:01:23 +04:00
Stefan Monnier
a9e4425bc9 * lisp/progmodes/ruby-mode.el: First cut at SMIE support.
(ruby-use-smie): New var.
(ruby-smie-grammar): New constant.
(ruby-smie--bosp, ruby-smie--implicit-semi-p)
(ruby-smie--forward-token, ruby-smie--backward-token)
(ruby-smie-rules): New functions.
(ruby-mode-variables): Setup SMIE if applicable.
* test/indent/ruby.rb: Fix indentation after =; add more cases.
2013-05-08 16:25:57 -04:00
Stefan Monnier
323885fd82 * lisp/progmodes/perl-mode.el: Add support for here documents.
(perl-syntax-propertize-function): Match here-doc markers.
(perl-syntax-propertize-special-constructs): Find their end.
(perl-imenu-generic-expression): Use [:alnum:].
2013-05-06 15:33:56 -04:00
Stefan Monnier
aa7dab9754 * lisp/progmodes/pascal.el (pascal--syntax-propertize): New const.
(pascal-mode): Use it.  Use setq-local.
(pascal-font-lock-keywords): Use backquotes.
Merge the two entries that handle function definitions.
* test/indent/pascal.pas: Add test for mis-identified comments.
2013-05-04 22:26:38 -04:00
Masatake YAMATO
38ef2c8490 Added bug number (Bug#14112) to my last ChangeLog entries. 2013-04-20 04:56:16 +09:00
Masatake YAMATO
1398a54d6a * automated/imenu-tests.el: New file. 2013-04-20 04:02:55 +09: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
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
Paul Eggert
54ac5d4745 Spelling fixes. 2013-04-14 14:57:21 -07:00
Masatake YAMATO
694569fc79 * test/automated/add-log-tests.el: New file.
Fixes: debbugs:14112
2013-04-10 02:37:17 +09:00
Paul Eggert
b9edfa5c63 Spelling fixes. 2013-04-01 00:58:04 -07: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
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
Paul Eggert
307d0e95ee Spelling fixes. 2013-03-10 21:07:45 -07:00
Glenn Morris
24958590a0 Add 24.3 release to ChangeLogs 2013-03-10 19:35:23 -07: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
Paul Eggert
2054a6c311 * indent/octave.m: Fix encoding error in comment. Add coding tag. 2013-03-05 00:06:54 -08:00
Glenn Morris
929aeac608 Merge from emacs-24; up to 2012-12-23T02:41:17Z!rgm@gnu.org 2013-02-27 22:30:48 -08:00
Fabián Ezequiel Gallina
b85f342318 * automated/python-tests.el
(python-tests-with-temp-buffer): Doc fix.
(python-tests-with-temp-file): New macro.
(python-tests-shell-interpreter): New var.
(python-shell-get-process-name-1)
(python-shell-internal-get-process-name-1)
(python-shell-parse-command-1)
(python-shell-calculate-process-environment-1)
(python-shell-calculate-process-environment-2)
(python-shell-calculate-process-environment-3)
(python-shell-calculate-exec-path-1)
(python-shell-calculate-exec-path-2)
(python-shell-make-comint-1)
(python-shell-make-comint-2)
(python-shell-get-process-1)
(python-shell-get-or-create-process-1)
(python-shell-internal-get-or-create-process-1): New tests.
2013-02-25 12:02:05 -03:00
Paul Eggert
52b823c8af Spelling fixes. 2013-02-24 23:49:40 -08: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
Glenn Morris
62cfd799f1 ChangeLog fix 2013-02-21 08:54:51 -08:00
Fabián Ezequiel Gallina
4dddd5dcda Added intial test suite for python.el.
* automated/python-tests.el
(python-tests-with-temp-buffer): New macro.
(python-tests-look-at): New function.
(python-tests-look-at-1)
(python-tests-look-at-2)
(python-indent-pep8-1)
(python-indent-pep8-2)
(python-indent-pep8-3)
(python-indent-inside-paren-1)
(python-indent-inside-paren-2)
(python-indent-after-block-1)
(python-indent-after-block-2)
(python-indent-dedenters-1)
(python-indent-after-backslash-1)
(python-indent-after-backslash-2)
(python-nav-beginning-of-defun-1)
(python-nav-beginning-of-defun-2)
(python-nav-end-of-defun-1)
(python-nav-end-of-defun-2)
(python-nav-beginning-of-statement-1)
(python-nav-end-of-statement-1)
(python-nav-forward-statement-
(python-nav-backward-statement-1)
(python-nav-backward-statement-2)
(python-nav-beginning-of-block-1)
(python-nav-end-of-block-1)
(python-nav-forward-block-1)
(python-nav-lisp-forward-sexp-safe-1)
(python-nav-forward-sexp-1)
(python-nav-forward-sexp-2)
(python-nav-forward-sexp-3)
(python-nav-up-list-1)
(python-nav-backward-up-list-1)
(python-imenu-prev-index-position-1)
(python-info-current-defun-1)
(python-info-current-defun-2)
(python-info-current-defun-3)
(python-info-current-symbol-1)
(python-info-current-symbol-2)
(python-info-current-symbol-3)
(python-info-statement-starts-block-p-1)
(python-info-statement-starts-block-p-2)
(python-info-statement-ends-block-p-1)
(python-info-statement-ends-block-p-2)
(python-info-beginning-of-statement-p-1)
(python-info-beginning-of-statement-p-2)
(python-info-end-of-statement-p-1)
(python-info-end-of-statement-p-2)
(python-info-beginning-of-block-p-1)
(python-info-beginning-of-block-p-2)
(python-info-end-of-block-p-1)
(python-info-end-of-block-p-2)
(python-info-closing-block-1)
(python-info-closing-block-2)
(python-info-line-ends-backslash-p-1)
(python-info-beginning-of-backslash-1)
(python-info-continuation-line-p-1)
(python-info-block-continuation-line-p-1)
(python-info-block-continuation-line-p-2)
(python-info-assignment-continuation-line-p-1)
(python-info-assignment-continuation-line-p-2)
(python-info-looking-at-beginning-of-defun-1)
(python-info-current-line-comment-p-1)
(python-info-current-line-empty-p)
(python-util-goto-line-1)
(python-util-clone-local-variables-1)
(python-util-forward-comment-1): New tests.
2013-02-20 17:27:08 -03:00
Dmitry Gutov
71a048c16b (ruby-add-log-current-method): Improve performance at the expense
of accuracy.  `ruby-block-contains-point' is relatively slow, so
only use it for method and singleton class blocks.

* test/automated/ruby-mode-tests.el
(ruby-add-log-current-method-after-inner-class): Lower
expectations: move point inside a method, initially.
2013-02-14 09:45:33 +04:00
Dmitry Gutov
53ca88c478 * lisp/progmodes/ruby-mode.el (ruby-parse-partial): Don't increase
depth for unfinished percent literal.  Not using it in the caller.
(ruby-move-to-block): Jump over multiline literals of all types,
ignoring code-looking contents inside them.

* test/automated/ruby-mode-tests.el
(ruby-move-to-block-skips-percent-literal): Add depth-affecting
bits inside the examples.
(ruby-move-to-block-skips-heredoc): New test.
2013-02-14 07:33:55 +04:00
Dmitry Gutov
7132e457ad * lisp/progmodes/ruby-mode.el (ruby-move-to-block): Improve
performance.  Instead of recalculating indentation fully for each
line, sum up indentation depth based only on visited lines.
(ruby-parse-partial): Increase the depth after "do" even when END
is right after it.
(ruby-parse-partial): When END is in the middle of a percent
literal, increase the depth if the delimiter chars belong to the
paren syntax class.

* test/automated/ruby-mode-tests.el
(ruby-move-to-block-skips-percent-literal): New test.
2013-02-13 12:15:05 +04:00
Chong Yidong
6e5c1569e9 Merge FFAP's URI-detection code into thingatpt.el.
* lisp/ffap.el: Require thingatpt.
(ffap-url-at-point): Delegate URI detection to thing-at-point.
All URI-valid characters are now recognized.
(ffap-string-at-point): Use use-region-p.
(ffap-url-regexp): Extra character is handled by thing-at-point.
(ffap-string-at-point-mode-alist): Allow parentheses.
(ffap-newsgroup-regexp, ffap-newsgroup-heads, ffap-newsgroup-p):
Convert to aliases; code moved to thingatpt.el.
(ffap-gnus-hook): Use setq-local.

* lisp/thingatpt.el: Rewrite the URL detection routines, absorbing some
code from ffap.el.
(thing-at-point-beginning-of-url-regexp): New var.
(thing-at-point-uri-schemes): Update list of URI schemes.
(thing-at-point-url-regexp): Variable deleted.
(thing-at-point-markedup-url-regexp): Disallow newlines.
(thing-at-point-newsgroup-regexp)
(thing-at-point-newsgroup-heads)
(thing-at-point-default-mail-uri-scheme): New variables.
(thing-at-point-bounds-of-url-at-point): Rewrite.  Use ffap's
method to find the possible bounds of the URI at point.  New
optional argument to find ill-formed URIs.
(thing-at-point-url-at-point): Rewrite.  New arguments for finding
ill-formed URIs.  Use thing-at-point-bounds-of-url-at-point, and
the scheme-adding heuristics from ffap-url-at-point.
(thing-at-point--bounds-of-well-formed-url): New function.  Do
parens matching to decide whether to include parens in the URI

* test/automated/thingatpt.el: New file.

Fixes: debbugs:5673
2013-02-04 20:02:25 +08:00
Chong Yidong
984096edf5 Fix byte compilation warning in files testsuite.
* automated/files.el (file-test--do-local-variables-test): Avoid
compilation warning message.
2013-02-03 16:55:45 +08:00
Stefan Monnier
c4f268a137 * lisp/progmodes/opascal.el: Rename from delphi.el. Use lexical-binding.
(opascal-newline-always-indents): Remove custom.
(opascal-tab, opascal-newline): Remove commands.
(opascal-new-comment-line): Insert "\n" instead of calling newline.
(opascal-mode-map): Keep default bindings for RET and TAB and DEL.
(opascal-save-match-data): Remove, use save-match-data instead.
(opascal-save-state): Use with-silent-modifications.
2013-01-30 20:58:24 -05:00
Dmitry Gutov
a324b8c791 * progmodes/ruby-mode.el (ruby-move-to-block): Work with (maybe
temporarily) broken indentation.
* automated/ruby-mode-tests.el (ruby-block-test-example):
  Break indentation of the do block opener and add a line inside it.
* automated/ruby-mode-tests.el (works-on-do, ok-with-three):
  Adjust line numbers.
2013-01-28 05:20:42 +04:00
Dmitry Gutov
b162502414 * automated/ruby-mode-tests.el
(ruby-indent-spread-args-in-parens): New test.
2013-01-28 02:47:34 +04:00
Stefan Monnier
cb9c0a53bc * lisp/emacs-lisp/advice.el (ad-preactivate-advice): Adjust the cleanup to
the use of nadvice.el.
* lisp/emacs-lisp/nadvice.el (advice--tweak): Make it possible for `tweak'
to return an explicit nil.
(advice--remove-function): Change accordingly.
* test/automated/advice-tests.el: Split up.  Add advice-test-preactivate.
2013-01-15 01:05:22 -05:00
Glenn Morris
51e7349210 Fix interpretation of gnu line.col1-col2 error message format
* lisp/progmodes/compile.el (compilation-error-regexp-alist-alist):
* test/automated/compile-tests.el (compile-tests--test-regexps-data):
Fix interpretation of gnu line.col1-col2 format.

Fixes: debbugs:13335
2013-01-13 17:08:13 -08:00
Wolfgang Jenkner
327a6ccaa0 * lisp/man.el: Handle different "man -k" behaviors. Use utf-8.
(Man-man-k-use-anchor): New var.
(Man-parse-man-k): New function.
(Man-completion-table): Use it.
(man): Flush the completion cache between uses.
* test/automated/man-tests.el: New file.

Fixes: debbugs:13160
2013-01-10 10:01:35 -05:00
Aaron S. Hawley
51fb557877 * test/automated/undo-tests.el (undo-test0): Adjust error to code change. 2013-01-09 16:29:27 -05:00
Aaron S. Hawley
3bace969f3 * lisp/simple.el (primitive-undo): Move from undo.c.
* src/undo.c (Fprimitive_undo): Move to simple.el.
(syms_of_undo): Remove declaration for Sprimitive_undo.
* test/automated/undo-tests.el: New file.
2013-01-08 14:13:31 -05:00
Stefan Monnier
4986fa2175 * lisp/emacs-lisp/advice.el (ad-activate-advised-definition): Refresh the
advice list when the interactive-spec of ad-Advice-* changes.
2013-01-07 13:03:01 -05:00
Stefan Monnier
4a74c81880 * lisp/view.el (view--enable, view--disable): Rename from view-mode-enable
and view-mode-disable and assume it's called from view-mode.
(view-mode-enable, view-mode-disable): Redefine as obsolete
compatibility layer above view-mode.
(view-mode-enter): Call `view-mode'.
* lisp/files.el (after-find-file): Call `view-mode'.
2013-01-03 21:53:48 -05:00
Paul Eggert
09b8afb6c8 Update copyright dates to 2013. 2013-01-02 08:30:50 -08:00
Paul Eggert
0877d0dc24 Merge from emacs-24; up to 2012-12-06T01:39:03Z!monnier@iro.umontreal.ca 2013-01-02 08:13:04 -08:00
Paul Eggert
ab422c4d68 Update copyright notices for 2013. 2013-01-01 09:11:05 +00:00
Paul Eggert
fee0bd5f32 Use URLs, not Boston addresses, in copyright notices. 2012-12-31 07:34:32 -08:00
Glenn Morris
82e2a1f054 Merge from emacs-24; up to 2012-12-03T21:07:47Z!eggert@cs.ucla.edu 2012-12-27 00:21:08 -08:00
Dmitry Gutov
db590ef6e3 * lisp/progmodes/ruby-mode.el (ruby-indent-beg-re): Only allow "class",
"module" and "def" to have indentation before them.  Regression
  from 2012-09-07T04:15:56Z!dgutov@yandex.ru (see the new test).

* test/automated/ruby-mode-tests.el
  (ruby-indent-after-block-in-continued-expression): New test.
2012-12-26 20:45:19 +04:00
Dmitry Gutov
bb808526ae * lisp/progmodes/ruby-mode.el (ruby-syntax-propertize-function):
Extract `ruby-syntax-propertize-expansions'.
(ruby-syntax-propertize-expansions): Only change syntax on
certain string delimiters, to punctuation.  This way the common
functions like forward-word and thing-at-point still work.
(ruby-match-expression-expansion): Improve readability.
(ruby-block-contains-point): New function.
(ruby-add-log-current-method): Handle several edge cases.

* test/automated/ruby-mode-tests.el
Rename one interpolation test; add three more.
(ruby-with-temp-buffer): New macro, use it where appropriate.
(ruby-add-log-current-method-examples): Use "_" for target point.
Add four tests for ruby-add-log-current-method.
2012-12-14 10:58:15 +04:00
Dmitry Gutov
dbb530d988 * lisp/progmodes/ruby-mode.el (ruby-syntax-propertize-function):
Extract `ruby-syntax-propertize-expansions'.
(ruby-syntax-propertize-expansions): Only change syntax on
certain string delimiters, to punctuation.  This way the common
functions like forward-word and thing-at-point still work.

* test/automated/ruby-mode-tests.el
Rename one interpolation test; add three more.
2012-12-14 08:55:23 +04:00
Glenn Morris
a0099d31a6 Fix for indentation of f90 preproc lines embedded in continuations
* lisp/progmodes/f90.el (f90-line-continued, f90-indent-region):
Treat preprocessor lines embedded in continuations like comments.
(f90-indent-line): Special-case preprocessor lines. 

* test/automated/f90.el (f90-test-bug13138): New test.
2012-12-10 20:42:49 -08:00
Rüdiger Sonderfeld
81606b1050 Support filesystem notification through inotify on GNU/Linux.
configure.ac (inotify): New option.
 (HAVE_INOTIFY): Test for inotify.

 src/termhooks.h (enum event_kind) [HAVE_INOTIFY]: Add
 FILE_NOTIFY_EVENT.
 src/lisp.h (syms_of_inotify) [HAVE_INOTIFY]: Add prototype.
 src/keyboard.c (Qfile_inotify) [HAVE_INOTIFY]: New variable.
 (syms_of_keyboard): DEFSYM it.
 (kbd_buffer_get_event) [HAVE_INOTIFY]: Generate FILE_NOTIFY_EVENT.
 (make_lispy_event): Support FILE_NOTIFY_EVENT by generating
 Qfile_inotify events.
 (keys_of_keyboard) [HAVE_INOTIFY]: Bind file-inotify events in
 special-event-map to inotify-handle-event.
 src/emacs.c (main) [HAVE_INOTIFY]: Call syms_of_inotify.
 src/Makefile.in (base_obj): Add inotify.o.
 src/inotify.c: New file.

 lisp/subr.el (inotify-event-p, inotify-handle-event): New functions.

 test/automated/inotify-test.el: New test.
2012-12-10 06:17:21 -05:00
Chong Yidong
89eb3b0ae7 Fix for bad test in ruby-mode-tests.el.
* automated/ruby-mode-tests.el (ruby-add-log-current-method-examples):
Don't use loop macro, to allow automated testing to work.
2012-12-02 14:06:32 +08:00
Stefan Monnier
23ba2705e2 Make called-interactively-p work for edebug or advised code.
* lisp/subr.el (called-interactively-p-functions): New var.
(internal--called-interactively-p--get-frame): New macro.
(called-interactively-p, interactive-p): Rewrite in Lisp.
* lisp/emacs-lisp/nadvice.el (advice--called-interactively-skip): New fun.
(called-interactively-p-functions): Use it.
* lisp/emacs-lisp/edebug.el (edebug--called-interactively-skip): New fun.
(called-interactively-p-functions): Use it.
* lisp/allout.el (allout-called-interactively-p): Don't assume
called-interactively-p is a subr.
* src/eval.c (Finteractive_p, Fcalled_interactively_p, interactive_p): Remove.
(syms_of_eval): Remove corresponding defsubr.
* src/bytecode.c (exec_byte_code): `interactive-p' is now a Lisp function.
* test/automated/advice-tests.el (advice-tests--data): Remove.
(advice-tests): Move the tests directly here instead.
Add called-interactively-p tests.
2012-11-19 23:24:09 -05:00
Stefan Monnier
19dc72069c Use cl-lib instead of cl, and interactive-p => called-interactively-p.
* lisp/erc/erc-track.el, lisp/erc/erc-networks.el, lisp/erc/erc-netsplit.el:
* lisp/erc/erc-dcc.el, lisp/erc/erc-backend.el: Use cl-lib, nth, pcase, and
called-interactively-p instead of cl.
* lisp/erc/erc-speedbar.el, lisp/erc/erc-services.el:
* lisp/erc/erc-pcomplete.el, lisp/erc/erc-notify.el, lisp/erc/erc-match.el:
* lisp/erc/erc-log.el, lisp/erc/erc-join.el, lisp/erc/erc-ezbounce.el:
* lisp/erc/erc-capab.el: Don't require cl since we don't use it.
* lisp/erc/erc.el: Use cl-lib, nth, pcase, and called-interactively-p i.s.o cl.
(erc-lurker-ignore-chars, erc-common-server-suffixes): Move before first use.
* lisp/json.el: Don't require cl since we don't use it.
* lisp/color.el: Don't require cl.
(color-complement): `caddr' -> `nth 2'.
* test/automated/ert-x-tests.el: Use cl-lib.
* test/automated/ert-tests.el: Use lexical-binding and cl-lib.
2012-11-19 12:24:12 -05:00
Stefan Monnier
dd0c5bbb36 * lisp/emacs-lisp/advice.el (ad-make-advised-definition): Improve last fix. 2012-11-16 13:02:39 -05:00
Dmitry Gutov
c62792e7df * lisp/progmodes/ruby-mode.el
(ruby-syntax-propertize-function): After everything else, search
for expansions in string literals, mark their insides as
whitespace syntax and save match data for font-lock.
(ruby-font-lock-keywords): Highlight just the 2nd group from
expression expansion matches.
(ruby-match-expression-expansion): Use the match data saved to the
text property in ruby-syntax-propertize-function.

* test/automated/ruby-mode-tests.el
Change direct font-lock face references to var references.
(ruby-interpolation-suppresses-syntax-inside): New test.
(ruby-interpolation-inside-percent-literal-with-paren): New
failing test.
2012-11-14 16:17:21 +04:00
Dmitry Gutov
8619323f69 * lisp/progmodes/ruby-mode.el (ruby-expr-beg): Make heredoc detection
more strict.  Add docstring.

* test/automated/ruby-mode-tests.el (ruby-indent-singleton-class): Pass.
(ruby-indent-inside-heredoc-after-operator)
(ruby-indent-inside-heredoc-after-space): New tests.
2012-11-14 10:34:17 +04:00
Dmitry Gutov
5e9419e849 * lisp/progmodes/ruby-mode.el (ruby-move-to-block): Looks for a block
start/end keyword a bit harder.  Works with different values of N.
Add more comments.
(ruby-end-of-block): Update accordingly.

* test/automated/ruby-mode-tests.el (ruby-heredoc-font-lock)
(ruby-singleton-class-no-heredoc-font-lock)
(ruby-add-log-current-method-examples): New tests.
(ruby-test-string): Extract from ruby-should-indent-buffer.
(ruby-deftest-move-to-block): New macro.
Add several move-to-block tests.
2012-11-13 22:57:26 +04:00
Stefan Monnier
3c442f8b25 * lisp/emacs-lisp/advice.el: Layer on top of nadvice.el.
Remove out of date self-require hack.
(ad-do-advised-functions): Use simple `dolist'.
(ad-advice-name, ad-advice-protected, ad-advice-enabled)
(ad-advice-definition): Redefine as functions.
(ad-advice-classes): Move before first use.
(ad-make-origname, ad-set-orig-definition, ad-clear-orig-definition)
(ad-make-mapped-call, ad-make-advised-docstring, ad-make-plain-docstring)
(ad--defalias-fset): Remove functions.
(ad-make-advicefunname, ad-clear-advicefunname-definition): New functions.
(ad-get-orig-definition): Rewrite.
(ad-make-advised-definition-docstring): Change base docstring.
(ad-real-orig-definition): Rewrite.
(ad-map-arglists): Change name of called function.
(ad--make-advised-docstring): Redirect `function' from ad-Advice-...
(ad-make-advised-definition): Simplify.
(ad-assemble-advised-definition): Tweak for new calling context.
(ad-activate-advised-definition): Setup ad-Advice-* instead of ad-Orig-*.
(ad--defalias-fset): Rename from ad-handle-definition.  Make it set the
function and call ad-activate if needed.
(ad-activate, ad-deactivate): Don't call ad-handle-definition any more.
(ad-recover): Clear ad-Advice-* instead of ad-Orig-*.
(ad-compile-function): Compile ad-Advice-*.
(ad-activate-on-top-level, ad-with-auto-activation-disabled): Remove.
(ad-start-advice, ad-stop-advice): Remove.
2012-11-13 09:12:46 -05:00
Dmitry Gutov
5745cae698 * lisp/progmodes/ruby-mode.el (ruby-add-log-current-method): Print the
period before class method names, not after.  Remove handling of
one impossible case.  Add comments.

* test/automated/ruby-mode-tests.el 
(ruby-add-log-current-method-examples): New test.
(ruby-test-string): Extract from ruby-should-indent-buffer.
2012-11-13 13:30:16 +04:00
Dmitry Gutov
f178c32dd1 * lisp/progmodes/ruby-mode.el (ruby-font-lock-keywords): Never
font-lock the beginning of singleton class as heredoc.

* test/automated/ruby-mode-tests.el (ruby-heredoc-font-lock)
(ruby-singleton-class-no-heredoc-font-lock): New tests.
2012-11-13 07:07:09 +04:00
Stefan Monnier
413d4689c0 * lisp/emacs-lisp/cl.el (dolist, dotimes, declare): Use advice-add to
override the default.
* lisp/emacs-lisp/cl-macs.el (cl-dolist, cl-dotimes): Rewrite without using
cl--dotimes/dolist.
* lisp/subr.el (dolist, dotimes, declare): Redefine them normally, even when
`cl' is loaded.

* lisp/emacs-lisp/nadvice.el (advice--normalize): New function, extracted
from add-advice.
(advice--strip-macro): New function.
(advice--defalias-fset): Use them to handle macros.
(advice-add): Use them.
(advice-member-p): Correctly handle macros.
2012-11-12 22:00:09 -05:00
Glenn Morris
f78ee6afc0 Merge from emacs-24; up to 2012-11-09T14:45:15Z!dmantipov@yandex.ru 2012-11-12 18:25:59 -08:00
Stefan Monnier
231d8498eb * lisp/emacs-lisp/nadvice.el: New package.
* lisp/subr.el (special-form-p): New function.
* lisp/emacs-lisp/elp.el: Use lexical-binding and advice-add.
(elp-all-instrumented-list): Remove var.
(elp-not-profilable): Remove elp-wrapper.
(elp-profilable-p): Use autoloadp and special-form-p.
(elp--advice-name): New const.
(elp-instrument-function): Use advice-add.
(elp--instrumented-p): New predicate.
(elp-restore-function): Use advice-remove.
(elp-restore-all, elp-reset-all): Use mapatoms.
(elp-set-master): Use elp--instrumented-p.
(elp--make-wrapper): Rename from elp-wrapper, return a function
suitable for advice-add.  Use cl-inf.
(elp-results): Use mapatoms+elp--instrumented-p.
* lisp/emacs-lisp/debug.el: Use lexical-binding and advice-add.
(debug-function-list): Remove var.
(debug): Rename arg, and then let-bind it explicitly inside.
(debugger-setup-buffer): Rename arg.
(debugger-setup-buffer): Adjust counts to new debug-on-entry setup.
(debugger-frame-number): Adjust to new debug-on-entry setup.
(debug--implement-debug-on-entry): Rename from
implement-debug-on-entry, add argument.
(debugger-special-form-p): Remove, use special-form-p instead.
(debug-on-entry): Use advice-add.
(debug--function-list): New function.
(cancel-debug-on-entry): Use it, along with advice-remove.
(debug-arglist, debug-convert-byte-code, debug-on-entry-1): Remove.
(debugger-list-functions): Use debug--function-list instead of
debug-function-list.
* lisp/emacs-lisp/advice.el (ad-save-real-definition): Remove, unused.
(ad-special-form-p): Remove, use special-form-p instead.
(ad-set-advice-info): Use add-function and remove-function.
(ad--defalias-fset): Adjust accordingly.
* test/automated/advice-tests.el: New tests.
2012-11-12 15:43:43 -05:00
Dmitry Gutov
d1e1e53dec * lisp/progmodes/ruby-mode.el (ruby-move-to-block): When moving
backward, always stop at indentation.  Reverts the change from
2012-08-12T22:06:56Z!monnier@iro.umontreal.ca.

Fixes: debbugs:12851
2012-11-12 05:11:06 +04:00
Stefan Monnier
3618df4590 * lisp/progmodes/sh-script.el (sh--inside-noncommand-expression):
Rename from sh--inside-arithmetic-expression, handle more cases.

Fixes: debbugs:11263
2012-10-30 23:10:25 -04:00
Stefan Monnier
b08b6da7fe * lisp/progmodes/sh-script.el (sh--inside-arithmetic-expression): New func.
(sh-font-lock-open-heredoc): Use it.

Fixes: debbugs:12770
2012-10-30 22:45:34 -04:00
Stefan Monnier
d7f9cc8528 * lisp/vc/diff-mode.el (diff-context->unified): Don't get confused by "hunk
header comments".
(diff-unified->context, diff-context->unified)
(diff-reverse-direction, diff-fixup-modifs): Use `use-region-p'.
2012-10-29 11:14:10 -04:00
Eli Zaretskii
8111f5e6f0 Adapt compile.el to changes in MSVC diagnostics format.
lisp/progmodes/compile.el (compilation-error-regexp-alist-alist):
 Adjust the msft regexp to the output of Studio 2010, and move msft
 before edg-1.  See the discussion on emacs-devel,
 http://lists.gnu.org/archive/html/emacs-devel/2012-09/msg00579.html,
 for the details.

 etc/compilation.txt (msft): Add error messages in new Studio 2010
 format.

 test/automated/compile-tests.el (compile-tests--test-regexps-data):
 Add data for msft's new format.
2012-10-14 09:40:05 +02:00
Dmitry Gutov
32fb816220 * lisp/progmodes/ruby-mode.el (ruby-brace-to-do-end): Don't add extra
whitespace after "end".
(ruby-do-end-to-brace): Collapse block to one line if it fits
within fill-column.
2012-09-19 02:10:19 +04:00
Dmitry Gutov
c326883141 * lisp/progmodes/ruby-mode.el (ruby-toggle-block): Guess the current block,
not just expect to be at its beginning.  Adjust callees.
Succeed when do-end block has no space before the pipe character.
(ruby-brace-to-do-end): When the original block is one-liner,
convert to multiline.  Reindent the result.

* test/automated/ruby-mode-tests.el:
(ruby-toggle-block-to-multiline): New test.
(ruby-should-indent-buffer, ruby-toggle-block-to-do-end)
(ruby-toggle-block-to-brace): Use buffer-string.
2012-09-09 03:32:25 +04:00
Dmitry Gutov
616c6c36aa * lisp/progmodes/ruby-mode.el (ruby-match-expression-expansion): Only
fail when reached LIMIT.
2012-09-08 19:13:14 +04:00
Dmitry Gutov
0ba2d4b646 * lisp/progmodes/ruby-mode.el (ruby-indent-beg-re): Add pieces from
ruby-beginning-of-indent, simplify, allow all keywords to have
indentation before them.
(ruby-beginning-of-indent): Adjust for above.  Search until the
found point is not inside a string or comment.
(ruby-font-lock-keywords): Allow symbols to start with "@"
character, give them higher priority than variables.
(ruby-syntax-propertize-function)
(ruby-font-lock-syntactic-keywords): Remove the "not comments"
matchers.  Expression expansions are not comments when inside a
string, and there comment syntax status is irrelevant.
(ruby-match-expression-expansion): New function.  Check that
expression expansion is inside a string, and it's not escaped.
(ruby-font-lock-keywords): Use it.

* test/automated/ruby-mode-tests.el: New tests (Bug#11613).
2012-09-07 08:15:56 +04:00
Glenn Morris
eada086196 Merge from emacs-24; up to 2012-05-04T19:17:01Z!monnier@iro.umontreal.ca 2012-08-28 09:01:59 -07:00
Chong Yidong
19c17fc147 Update release logs 2012-08-24 17:53:39 +08:00
Chong Yidong
450809af98 * src/xdisp.c (handle_invisible_prop): Fix ellipses at overlay string ends.
* test/redisplay-testsuite.el (test-redisplay): Use switch-to-buffer.

Fixes: debbugs:3874
2012-08-20 00:19:05 +08:00
Chong Yidong
a999ce26e9 Make display strings obey buffer-invisibility-spec.
* src/xdisp.c (handle_invisible_prop): Obey TEXT_PROP_MEANS_INVISIBLE
for the string case.

* redisplay-testsuite.el (test-redisplay-4): New test.

Fixes: debbugs:3874
2012-08-18 15:23:30 +08:00
Chong Yidong
ddf0e868c2 Bump version to 24.2 2012-08-16 00:12:37 +08:00
Dmitry Gutov
f063063a8a * lisp/progmodes/ruby-mode.el (ruby-syntax-methods-before-regexp): New const.
(ruby-syntax-propertize-function): Use it to recognize regexps.
Don't look at the text after regexp, just use the whitelist.
* test/indent/ruby.rb: Rearrange examples, add new ones.

Fixes: debbugs:6286
2012-08-14 08:38:11 -04:00
Chong Yidong
45e7ed7165 Improve the file-local variable regression test.
* test/automated/files.el: Test every combination of values for
enable-local-variables and enable-local-eval.
2012-08-14 12:04:25 +08:00
Nobuyoshi Nakada
0d9e2599ec Merge from upstream ruby-mode.el
* lisp/progmodes/ruby-mode.el (ruby-mode-map): Remove unnecessary
binding for `newline'.
(ruby-move-to-block): When moving backward, stop at block opening,
not indentation.
* progmodes/ruby-mode.el (ruby-brace-to-do-end)
(ruby-do-end-to-brace, ruby-toggle-block): New functions.
* progmodes/ruby-mode.el (ruby-mode-map): Add binding for
`ruby-toggle-block'.
* test/automated/ruby-mode-tests.el (ruby-move-to-block-stops-at-opening)
(ruby-toggle-block-to-do-end, ruby-toggle-block-to-brace): New test.
2012-08-12 18:06:56 -04:00
Glenn Morris
9ff9402d3a ChangeLog date fixes 2012-08-10 21:46:38 -07:00
Chong Yidong
5725bd2cc0 Merge from emacs-24; up to 2012-05-02T11:38:01Z!lekktu@gmail.com 2012-08-11 10:13:55 +08:00
Dmitry Gutov
9d2ed8a27e * test/automated/ruby-mode-tests.el (ruby-should-indent):
Add docstring, check (current-indentation) instead of (current-column).
(ruby-should-indent-buffer): New function.
Add tests for `ruby-deep-indent-paren' behavior.
Port all tests from test/misc/test_ruby_mode.rb in Ruby repo.

Fixes: debbugs:12169
2012-08-10 16:25:43 -04:00
Dmitry Gutov
9cd80478d6 Merge stuff from upsteam ruby-mode, part 1.
* lisp/progmodes/ruby-mode.el (ruby-mode-map): Remove deprecated
binding (use `M-;' instead).
(ruby-expr-beg, ruby-parse-partial): ?, _, and : are symbol
constituents, ! is not (but kinda should be).
(ruby-singleton-class-p): New function.
(ruby-expr-beg, ruby-in-here-doc-p)
(ruby-syntax-propertize-heredoc): Use it.
(ruby-syntax-propertize-function): Adjust for changes in
`ruby-syntax-propertize-heredoc'.

* test/automated/ruby-mode-tests.el (ruby-should-indent)
(ruby-assert-state): New functions.
Add new tests.

Fixes: debbugs:12169
2012-08-10 16:19:09 -04:00
Glenn Morris
711f4590cd * test/automated/files.el (files-test-disable-local-variables): New test. 2012-08-10 00:13:06 -07:00
Glenn Morris
5f168c207f * test/automated/files.el: New file. 2012-08-08 00:33:10 -07:00
Glenn Morris
bf1757d19a * test/automated/Makefile.in (all): Fix typo. 2012-08-07 15:11:18 -04:00
David Engster
c91562a619 New tests for XML name expansion.
* automated/xml-parse-tests.el (xml-parse-tests--qnames): New
variable to hold test data for name expansion.
(xml-parse-tests): Test the two different types of name expansion.
2012-07-29 21:57:28 +02:00
Juri Linkov
d8efda90aa * test/automated/occur-tests.el (occur-test-case): Use predefined
buffer name " *test-occur*" instead of a random buffer name.
2012-07-29 03:12:13 +03:00
Dmitry Gutov
c28662a8dc * lisp/progmodes/ruby-mode.el (ruby-parse-partial): No error when end
up inside string symbol literal.
* test/automated/ruby-mode-tests.el: New file with one test.

Fixes: debbugs:11923
2012-07-20 07:10:25 -04:00
Stefan Monnier
efc26dbecd * lisp/progmodes/sh-script.el (sh-syntax-propertize-function): Mark "${#VAR"
as not-a-comment.
* test/indent/shell.sh: Add test case for ${#VAR}.

Fixes: debbugs:11946
2012-07-17 04:38:12 -04:00
Stefan Monnier
45fd731c4d * lisp/textmodes/tex-mode.el (tex-font-lock-keywords-1): Highlight not only
$$..$$ but also $..$ using regexps.
Use tex-verbatim for \url and \path.
(tex-font-lock-keywords): Define as defconst like the others.
(tex-common-initialization): Don't use font-lock-syntax-table any more.
* test/indent/latex-mode.tex: New file.

Fixes: debbugs:11953
2012-07-17 04:11:31 -04:00
Stefan Monnier
a464a6c73a More CL cleanups and reduction of use of cl.el.
* woman.el, winner.el, vc/vc-rcs.el, vc/vc-hooks.el, vc/vc-hg.el:
* vc/vc-git.el, vc/vc-dir.el, vc/vc-bzr.el, vc/vc-annotate.el:
* textmodes/tex-mode.el, textmodes/sgml-mode.el, tar-mode.el:
* strokes.el, ses.el, server.el, progmodes/js.el, progmodes/gdb-mi.el:
* progmodes/flymake.el, progmodes/ebrowse.el, progmodes/compile.el:
* play/tetris.el, play/snake.el, play/pong.el, play/landmark.el:
* play/hanoi.el, play/decipher.el, play/5x5.el, nxml/nxml-mode.el:
* net/secrets.el, net/quickurl.el, midnight.el, mail/footnote.el:
* image-dired.el, ibuffer.el, ibuf-macs.el, ibuf-ext.el, hexl.el:
* eshell/eshell.el, eshell/esh-io.el, eshell/esh-ext.el:
* eshell/esh-cmd.el, eshell/em-ls.el, eshell/em-hist.el:
* eshell/em-cmpl.el, eshell/em-banner.el:
* url/url.el, url/url-queue.el, url/url-parse.el, url/url-http.el:
* url/url-future.el, url/url-dav.el, url/url-cookie.el:
* calendar/parse-time.el, test/eshell.el: Use cl-lib.
* wid-browse.el, wdired.el, vc/vc.el, vc/vc-mtn.el, vc/vc-cvs.el:
* vc/vc-arch.el, tree-widget.el, textmodes/texinfo.el:
* textmodes/refill.el, textmodes/css-mode.el, term/tvi970.el:
* term/ns-win.el, term.el, shell.el, ps-samp.el:
* progmodes/perl-mode.el, progmodes/pascal.el, progmodes/gud.el:
* progmodes/glasses.el, progmodes/etags.el, progmodes/cwarn.el:
* play/gamegrid.el, play/bubbles.el, novice.el, notifications.el:
* net/zeroconf.el, net/xesam.el, net/snmp-mode.el, net/mairix.el:
* net/ldap.el, net/eudc.el, net/browse-url.el, man.el:
* mail/mailheader.el, mail/feedmail.el:
* url/url-util.el, url/url-privacy.el, url/url-nfs.el, url/url-misc.el:
* url/url-methods.el, url/url-gw.el, url/url-file.el, url/url-expand.el:
Dont use CL.
* ibuf-ext.el (ibuffer-mark-old-buffers): Use float-time.
* eshell/esh-opt.el (eshell-eval-using-options): Quote code with
`lambda' rather than with `quote'.
(eshell-do-opt): Adjust accordingly.
(eshell-process-option): Simplify.
* eshell/esh-var.el:
* eshell/em-script.el: Require `esh-opt' for eshell-eval-using-options.
* emacs-pcase.el (pcase--dontcare-upats, pcase--let*)
(pcase--expand, pcase--u1): Rename pcase's internal `dontcare' pattern
to `pcase--dontcare'.
* emacs-cl.el (labels): Mark obsolete.
(cl--letf, letf): Move to cl-lib.
(cl--letf*, letf*): Remove.
* emacs-cl-lib.el (cl-nth-value): Use defalias.
* emacs-cl-macs.el (cl-dolist, cl-dotimes): Add indent rule.
(cl-progv): Rewrite.
(cl--letf, cl-letf): Move from cl.el.
(cl-letf*): New macro.
* emacs-cl-extra.el (cl--progv-before, cl--progv-after): Remove.
2012-07-11 19:13:41 -04:00
Chong Yidong
566df3fcac Clean up syntax-table usage in xml.el
* xml.el (xml--parse-buffer): Use xml-syntax-table.
(xml-parse-tag): Likewise, and avoid changing entity tables.
(xml-syntax-table): Define from scratch, making sure not to give
x2000 and other Unicode spaces whitespace syntax, since those are
not spaces in XML.
(xml-parse-fragment): Delete unused function.
(xml-name-start-char-re, xml-name-char-re, xml-name-re)
(xml-names-re, xml-nmtoken-re, xml-nmtokens-re, xml-char-ref-re)
(xml-entity-ref, xml-pe-reference-re)
(xml-reference-re,xml-att-value-re, xml-tokenized-type-re)
(xml-notation-type-re, xml-enumeration-re, xml-enumerated-type-re)
(xml-att-type-re, xml-default-decl-re, xml-att-def-re)
(xml-entity-value-re): Use syntax references in regexps where
possible; no need to define inside a let-binding.
(xml-parse-dtd): Use xml-pe-reference-re.
(xml-entity-or-char-ref-re): New defconst.
(xml-parse-string, xml-substitute-special): Use it.
2012-07-05 00:14:05 +08:00
Chong Yidong
a76e6535dc * xml.el: Protect parser against XML bombs.
(xml-entity-expansion-limit): New variable.
(xml-parse-string, xml-substitute-special): Use it.
(xml-parse-dtd): Avoid infloop if the DTD is not terminated.

* test/automated/xml-parse-tests.el: Update testcases.
2012-07-03 13:28:42 +08:00
Chong Yidong
a7aef6f5c6 * lisp/xml.el: Handle entity and character reference expansion correctly.
(xml-default-ns): New variable.
(xml-entity-alist): Use XML spec definitions for lt and amp.
(xml-parse-region): Make first two arguments optional.  Discard
text properties.
(xml-parse-tag-1): New function, spun off from xml-parse-tag.  All
callers changed.
(xml-parse-tag): Call xml-parse-tag-1.  For backward
compatibility, this function should not modify buffer contents.
(xml-parse-tag-1): Fix opening-tag regexp.
(xml-parse-string): Rewrite, handling entity and character
references properly.
(xml--entity-replacement-text): Signal an error if a parameter
entity is undefined.

* test/automated/xml-parse-tests.el (xml-parse-tests--data): More
testcases.
2012-07-03 00:21:54 +08:00
Chong Yidong
6fe566a752 * xml.el (xml-parse-dtd): Use proper regexps for ELEMENT declarations.
* test/automated/xml-parse-tests.el: Update testcase.

Fixes: debbugs:7172
2012-07-01 19:05:17 +08:00
Chong Yidong
fbf2e7ad3b Improve xml parameter entity parsing, and add a new ERT test.
* test/automated/xml-parse-tests.el: New file.

* lisp/xml.el (xml--parse-buffer): New function.  Move most of
xml-parse-region here.
(xml-parse-region): Copy region into a temporary buffer, since
parameter entity substitution requires changing buffer contents.
Use xml--parse-buffer.
(xml-parse-file): Use xml--parse-buffer.
(xml-parse-dtd): Make parameter entity substitution work right.
2012-07-01 15:17:05 +08:00
Stefan Monnier
d5c6faf921 * lisp/emacs-lisp/cl.el (flet): Mark obsolete.
* lisp/emacs-lisp/cl-macs.el (cl-flet*): New macro.
* lisp/vc/vc-rcs.el (vc-rcs-annotate-command, vc-rcs-parse):
* lisp/progmodes/js.el (js-c-fill-paragraph):
* lisp/progmodes/ebrowse.el (ebrowse-switch-member-buffer-to-sibling-class)
(ebrowse-switch-member-buffer-to-derived-class):
* test/automated/ert-x-tests.el (ert-test-run-tests-interactively-2):
* lisp/play/5x5.el (5x5-solver): Use cl-flet.

Fixes: debbugs:11780
2012-06-27 11:11:28 -04:00
Ulf Jasper
ee5747918f icalendar / icalendar-tests: Fix Bug#11473 -- unescape commas in timezone specs
2012-06-08 Nick Dokos <nicholas.dokos@hp.com>

	* calendar/icalendar.el (icalendar--parse-vtimezone): Import TZID
	string properly, fixes Bug#11473.

2012-06-08  Ulf Jasper  <ulf.jasper@web.de>

	* automated/icalendar-tests.el (icalendar--parse-vtimezone): Test
	escaped commas in TZID (Bug#11473).
	(icalendar-import-with-timezone): New.
	(icalendar-real-world): Add new testcase as found in the bugreport
	of Bug#11473.
2012-06-08 19:34:09 +02:00
Chong Yidong
94f0aa3464 Bump version to 24.1.
Add release logs.
Regenerate AUTHORS and ldefs-boot.el.
2012-06-01 17:51:00 +08:00
Ulf Jasper
6dbaa1c769 icalendar-tests: Fix Bug#11525 -- Add icalendar-import-format-uid
2012-05-29  Ulf Jasper  <ulf.jasper@web.de>

	* calendar/icalendar.el
	(icalendar-export-region): Export UID properly.

2012-05-29 Leo Liu <sdl.web@gmail.com>
	* calendar/icalendar.el (icalendar-import-format): Add
	`icalendar-import-format-uid' (Bug#11525).
	(icalendar-import-format-uid): New.
	(icalendar--parse-summary-and-rest, icalendar--format-ical-event):
	Export UID.
2012-05-29 21:42:49 +02:00
Stefan Monnier
5814f126ba * lisp/progmodes/compile.el (compilation-error-regexp-alist-alist):
Simplify Maven regexp, and make sure the file can't start with a space.

Fixes: debbugs:11517
2012-05-21 00:28:41 -04:00
Glenn Morris
b847032c75 Command substitution already runs in a subshell
* Makefile.in (install-arch-indep, install-doc, install-info, uninstall):
* leim/Makefile.in (leim-list.el, install):
* lib-src/Makefile.in (insrcdir, $(DESTDIR)${archlibdir}):
* lisp/Makefile.in (setwins, setwins_almost, setwins_for_subdirs):
* test/automated/Makefile.in (setwins):
Scrap superfluous subshells.
2012-05-20 17:44:34 -07:00
Ted Zlatanov
5e561bc76d add url-util.el test file
* automated/url-util-tests.el: New file to test
lisp/url/url-util.el.  Only `url-build-query-string' and
`url-parse-query-string' are tested right now.
2012-05-15 04:52:15 -04:00
Stefan Monnier
461ef3c518 Add some shell indentation test cases.
* test/indent/shell.sh:
* test/indent/shell.rc: Add some test cases.
2012-04-28 16:04:34 -04:00
Stefan Monnier
dfbd787fe6 * lisp/progmodes/ruby-mode.el: Simplify last change, and cleanup code.
(ruby-syntax-propertize-regexp): Remove.
(ruby-syntax-propertize-function): Split regexp into chunks.
Match following code directly.
* test/indent/ruby.rb: New file, to test new syntax-propertize code.
2012-04-24 13:06:12 -04:00
Glenn Morris
ab7ce8c155 Add another vc-bzr test
* lisp/vc/vc-bzr.el (vc-bzr-status): Avoid condition-case-unless-debug.

* test/automated/vc-bzr.el (vc-bzr-test-faulty-bzr-autoloads): New test.
2012-04-10 20:24:26 -07:00
Ted Zlatanov
6c0c7cfc67 Move url-future.el ERT test to test/automated/url-future-tests.el.
* lisp/url/url-future.el (url-future-test): Move to test/automated.

* test/automated/url-future-tests.el (url-future-tests): Move from
lisp/url/url-future.el and rename.
2012-02-13 13:45:36 -05:00
Juanma Barranquero
6df6ae42fe Fix typos in ChangeLogs. 2012-01-31 17:15:03 +01:00
Ulf Jasper
bdbc1c4e3e test/automated/icalendar-tests: Fix broken test
2012-01-29  Ulf Jasper  <ulf.jasper@web.de>

	* automated/icalendar-tests.el (icalendar-import-non-recurring):
	Fix broken test, caused by missing trailing blank.
2012-01-29 13:28:20 +01:00
Glenn Morris
acaf905b11 Add 2012 to FSF copyright years for Emacs files 2012-01-05 01:46:05 -08:00
Paul Eggert
22bcf20469 Spelling fixes. 2011-12-30 17:27:15 -08:00
Paul Eggert
99d990817c Spelling fixes. 2011-12-18 22:21:24 -08:00
Paul Eggert
a87ef89906 Spelling fixes. 2011-12-15 14:14:12 -08:00
Stefan Monnier
15e0efc7dc * lisp/progmodes/pascal.el: Declare `ind' as dyn-bound.
Fixes: debbugs:10264
2011-12-13 10:33:25 -05:00
Paul Eggert
c80e3b4aed Spelling fixes. 2011-12-04 00:02:42 -08:00
Chong Yidong
5c09001c73 Fix for compilation-tests.el testsuite
* automated/compile-tests.el (compile-tests--test-regexps-data):
Increase column numbers by one to reflect change in how
compilation-message is recorded	(Bug#10172).
2011-12-03 11:04:21 +08:00
Paul Eggert
ee7683ebb7 Spelling fixes. 2011-11-22 23:03:56 -08:00
Glenn Morris
394c65f1c1 Move rmailmm test functions to test/ directory.
* lisp/mail/rmailmm.el (test-rmail-mime-handler)
(test-rmail-mime-bulk-handler)
(test-rmail-mime-multipart-handler): Move tests to test/ directory.

* test/rmailmm.el: New file, split from lisp/mail/rmailmm.el.
2011-11-21 21:55:06 -05:00
Juanma Barranquero
fe7a3057a3 Fix typos. 2011-11-20 20:35:27 +01:00
Juanma Barranquero
cd1181dbec Fix typos. 2011-11-20 04:48:53 +01:00
Paul Eggert
e1dbe924b5 Spelling fixes. 2011-11-19 18:29:42 -08:00
Paul Eggert
5396468298 Spelling fixes. 2011-11-19 01:18:31 -08:00
Paul Eggert
4c36be58ca Spelling fixes. 2011-11-17 01:09:20 -08:00
Juanma Barranquero
7877f37394 Fix typos. 2011-11-16 18:47:25 +01:00
Juanma Barranquero
58179ccebd Fix typos. 2011-11-16 13:34:47 +01:00
Juanma Barranquero
c701515351 Fix typos. 2011-11-15 18:37:37 +01:00
Paul Eggert
da6062e6ea Spelling fixes. 2011-11-14 23:55:13 -08:00
Paul Eggert
91af3942e9 Spelling fixes. 2011-11-14 15:59:56 -08:00
Paul Eggert
8350f087ef Spelling fixes. 2011-11-14 12:23:26 -08:00
Stefan Monnier
d9ac1a1e5d * lisp/progmodes/compile.el: Adjust regexp for OCaml warnings.
(compilation-error-regexp-alist-alist): OCaml warnings (can?) have a number.

Fixes: debbugs:9749
2011-11-09 10:39:32 -05:00
Ulf Jasper
dba0634a93 newsticker: Clean up newsticker--group-manage-orphan-feeds
2011-10-30  Ulf Jasper  <ulf.jasper@web.de>

	* net/newst-treeview.el: Remove "Time-stamp".
	(newsticker--group-manage-orphan-feeds): Do not call
	newsticker--treeview-tree-update.
	(newsticker-treeview-update, newsticker-treeview): Call
	newsticker--treeview-tree-update if necessary.

2011-10-30  Ulf Jasper  <ulf.jasper@web.de>

	* automated/newsticker-tests.el
	(newsticker--group-manage-orphan-feeds): Removed fsetting of
	newsticker--treeview-tree-update.
2011-10-30 16:21:37 +01:00
Ulf Jasper
73c3f81d49 newsticker: Fixed bug#9763, again
2011-10-29  Ulf Jasper  <ulf.jasper@web.de>

	* automated/newsticker-tests.el
	(newsticker--group-manage-orphan-feeds): Use fset instead of flet.
2011-10-29 17:29:16 +02:00
Ulf Jasper
6d6a626c20 newsticker: Fixed bug#9763
2011-10-29  Ulf Jasper  <ulf.jasper@web.de>

	* trunk/test/automated/newsticker-tests.el
	(newsticker--group-manage-orphan-feeds): Prevent updating
	newsticker treeview. Fixed bug#9763.
2011-10-29 17:17:30 +02:00
Glenn Morris
e195ae68f8 * test/automated/vc-bzr.el (vc-bzr-test-bug9781): New test. 2011-10-20 18:23:54 -04:00
Glenn Morris
6e0a9be7c9 * test/automated/vc-bzr.el: New file. 2011-10-19 20:39:45 -07:00
Glenn Morris
21fedf28e5 * test/automated/f90.el: New file. 2011-10-15 13:56:02 -07:00
Ulf Jasper
81416b68d8 Move test/newsticker-testsuite.el to automated/newsticker-tests.el
2011-09-27  Ulf Jasper  <ulf.jasper@web.de>

	* automated/newsticker-tests.el: Move newsticker-testsuite.el
	to automated/newsticker-tests.el. Convert to ERT.
2011-09-27 20:52:00 +02:00
Ulf Jasper
68575ab00b icalendar: Take care of multiple vcalendars in a single file.
lisp/ChangeLog:

	* calendar/icalendar.el (icalendar--all-events): Take care of
	multiple vcalendars in a single file.
	(icalendar--convert-float-to-ical): checkdoc fixes.

	* automated/icalendar-tests.el (icalendar-tests--compare-strings):
	Removed, simply use string=.
	(icalendar--diarytime-to-isotime)
	(icalendar--datetime-to-diary-date)
	(icalendar--datestring-to-isodate)
	(icalendar--format-ical-event)
	(icalendar--parse-summary-and-rest)
	(icalendar-tests--do-test-import)
	(icalendar-tests--do-test-cycle) : Changed argument order of
	string= to EXPECTED ACTUAL.
	(icalendar--import-format-sample)
	(icalendar--format-ical-event)
	(icalendar-import-non-recurring)
	(icalendar-import-rrule)
	(icalendar-import-duration)
	(icalendar-import-bug-6766)
	(icalendar-real-world): Adjusted to string= instead of
	icalendar-tests--compare-strings.
	(icalendar-import-multiple-vcalendars): New.
2011-07-26 17:36:04 +02:00
Juanma Barranquero
5eba16a37c Fix typos. 2011-07-14 03:09:00 +02:00
Glenn Morris
2af3e0b1d3 Use a single Author: header. 2011-05-14 13:13:30 -07:00
Ted Zlatanov
1c23108015 * automated/gnus-tests.el: Require CL. 2011-05-11 16:34:40 -05:00
Ted Zlatanov
de31677841 * automated/gnus-tests.el: Add wrapper for Gnus tests. 2011-05-11 16:31:33 -05:00
Juri Linkov
c07b2710c7 * test/automated/occur-tests.el: Move from test/occur-testsuite.el.
Convert to ERT.
2011-05-10 03:21:32 +04:00
Chong Yidong
adec429a62 Add regression test for compilation-error-regexp-alist-alist.
* test/automated/compile-tests.el: New file.
2011-05-08 21:22:05 -04:00
Chong Yidong
c4c205d05a Convert test/comint-testsuite.el to ERT format. 2011-05-08 17:43:07 -04:00
Juanma Barranquero
3338398778 Update and split ChangeLogs. 2011-04-06 14:18:10 +02:00
Stefan Monnier
7200d79c65 Miscellanous cleanups in preparation for the merge.
* lisp/emacs-lisp/byte-opt.el (byte-optimize-form-code-walker):
Remove debug statement.
* lisp/emacs-lisp/bytecomp.el (byte-compile-single-version)
(byte-compile-version-cond, byte-compile-delay-out)
(byte-compile-delayed-out): Remove, unused.
* src/bytecode.c (Fbyte_code): Revert to old calling convention.
* src/lisp.h (COMPILED_PUSH_ARGS): Remove, unused.
2011-04-01 11:16:50 -04:00
Stefan Monnier
6c075cd7c0 Rewrite the cconv conversion algorithm, for clarity.
* lisp/emacs-lisp/byte-opt.el (byte-compile-inline-expand): Adjust check for
new byte-code representation.
* lisp/emacs-lisp/cconv.el (cconv--convert-function): Rename from
cconv-closure-convert-function.
(cconv-convert): Rename from cconv-closure-convert-rec.
(cconv--analyse-use): Rename from cconv-analyse-use.
(cconv--analyse-function): Rename from cconv-analyse-function.
(cconv--analyse-use): Change some patterns to silence compiler.
(cconv-convert, cconv--convert-function): Rewrite.
* test/automated/lexbind-tests.el: New file.
2011-03-09 22:48:44 -05:00
Glenn Morris
81fb60b2aa Move eshell's self-tests to the test/ directory.
* lisp/eshell/esh-var.el: Don't require esh-test when compiling.
* lisp/eshell/em-banner.el, lisp/eshell/esh-cmd.el, lisp/eshell/esh-mode.el:
* lisp/eshell/esh-var.el, lisp/eshell/eshell.el: Move tests to esh-test.
* lisp/eshell/esh-test.el: Move to ../../test/eshell.el

* test/eshell.el: Move here from lisp/eshell/esh-test.el.
2011-03-05 12:07:27 -08:00
Christian Ohler
de69c0a8d1 Added fast path to ERT explanation of `equal'.
* emacs-lisp/ert.el (ert--explain-equal): New function.
(ert--explain-equal-rec): Renamed from `ert--explain-not-equal'.
All callers changed.
(ert--explain-equal-including-properties): Renamed from
`ert--explain-not-equal-including-properties'.  All callers
changed.
* automated/ert-tests.el (ert-test-explain-not-equal-keymaps):
New test.
2011-03-03 02:01:51 -07:00
Ulf Jasper
4856384c16 Convert test/icalendar-testsuite.el to ERT format.
* automated/icalendar-tests.el: Move from icalendar-testsuite.el;
  convert to ERT format.
2011-02-20 15:35:58 +01:00
Chong Yidong
aa0935b987 Convert test/bytecomp-testsuite.el to ERT format.
* automated/bytecomp-tests.el: Move from bytecomp-testsuite.el;
convert to ERT format.
2011-02-14 16:21:42 -05:00
Stefan Monnier
ccded26c1e * lisp/progmodes/sh-script.el (sh-font-lock-open-heredoc): Fix case
of here-doc that immediately follows a comment.
* .bzrignore: Ignore globals.h and related stamp.
* test/indent/shell.sh:
* test/indent/shell.rc: New files.
2011-02-09 13:59:55 -05:00
Chong Yidong
372fb76be9 Convert font parse testsuite to an ERT test.
* test/automated/font-parse-tests.el: Move from
font-parse-testsuite.el.

* src/font.c (font_parse_fcname): Undefine a temporary macro.
2011-01-27 18:45:04 -05:00
Chong Yidong
6608a7d8fb * src/font.c (font_parse_fcname): Rewrite GTK font name parser.
* test/font-parse-testsuite.el (test-font-parse-data): New file.
2011-01-26 13:10:04 -05:00
Glenn Morris
73b0cd5003 Convert consecutive FSF copyright years to ranges. 2011-01-24 20:08:28 -08:00
Glenn Morris
0d9f702fd0 Nuke arch-tags. 2011-01-15 15:16:57 -08:00
Glenn Morris
d0d4361dba Add 2011 to remaining FSF/AIST copyright years. 2011-01-15 14:10:37 -08:00
Stefan Monnier
77ab81d054 Merge from emacs-23 2011-01-14 12:18:41 -05:00
Stefan Monnier
db5d03ea56 * test/indent/prolog.prolog: Add tokenizing tests. 2011-01-13 15:53:06 -05:00
Christian Ohler
d221e7808c Add ERT, a tool for automated testing in Emacs Lisp.
* Makefile.in, configure.in, doc/misc/Makefile.in, doc/misc/makefile.w32-in:
Add ERT.  Make "make check" run tests in test/automated.

* doc/misc/ert.texi, lisp/emacs-lisp/ert.el, lisp/emacs-lisp/ert-x.el:
New files.

* test/automated: New directory.
2011-01-13 03:08:24 +11:00
Glenn Morris
5df4f04cd3 Add 2011 to FSF/AIST copyright years. 2011-01-02 15:50:46 -08:00
Stefan Monnier
cbf83ce9f9 * lisp/progmodes/modula2.el: Use SMIE and skeleton.
(m2-mode-syntax-table): (*..*) can be nested.
Add //...\n.  Fix paren syntax.
(m2-mode-map): Remove LF and TAB bindings.
(m2-indent): Add safety property.
(m2-smie-grammar): New var.
(m2-smie-refine-colon, m2-smie-refine-of, m2-smie-backward-token)
(m2-smie-forward-token, m2-smie-refine-semi, m2-smie-rules): New funs.
(m2-mode): Use define-derived-mode.
(m2-newline, m2-tab): Remove.
(m2-begin, m2-case, m2-definition, m2-else, m2-for, m2-header)
(m2-if, m2-loop, m2-module, m2-or, m2-procedure, m2-with, m2-record)
(m2-stdio, m2-type, m2-until, m2-var, m2-while, m2-export)
(m2-import): Use define-skeleton.
* test/indent/modula2.mod: New file.
2010-11-11 16:06:15 -05:00
Stefan Monnier
d19dc73db6 * test/indent/octave.m: Add a test to ensure indentation is local. 2010-10-27 10:48:05 -04:00
Glenn Morris
41f592d1b5 * test/comint-testsuite.el
(comint-testsuite--test-comint-password-prompt-regexp):
Add "Please enter the password".  (Bug#7224)
2010-10-23 12:51:14 -07:00
Stefan Monnier
3672149f83 * lisp/progmodes/pascal.el (pascal-mode): Use define-derived-mode.
Set invisibility spec for pascal's outline mode.
(pascal-outline-change): Clean up calling convention.
(pascal-show-all, pascal-hide-other-defuns): Update callers.
2010-09-20 16:57:01 +02:00
Stefan Monnier
549d0e1ec4 * lisp/progmodes/prolog.el (prolog-smie-forward-token)
(prolog-smie-backward-token): New functions.
(prolog-mode-variables): Use them to parse "!," correctly.
Set up smie-blink-matching for ".".
* test/indent/prolog.prolog: Use normal spacing around !.
2010-09-20 16:22:16 +02:00
Stefan Monnier
f5632fb6c2 * lisp/indent.el (indent-according-to-mode): Apply syntax-propertize.
(indent-region): Use indent-according-to-mode.
* test/indent/octave.m: Remove one more `fixindent'.  Use `end'.
2010-09-18 18:21:16 +02:00
Stefan Monnier
cf38dd4298 New syntax-propertize functionality.
* lisp/font-lock.el (font-lock-syntactic-keywords): Make obsolete.
(font-lock-fontify-syntactic-keywords-region): Move handling of
font-lock-syntactically-fontified to...
(font-lock-default-fontify-region): ...here.
Let syntax-propertize-function take precedence.
(font-lock-fontify-syntactically-region): Cal syntax-propertize.

* lisp/emacs-lisp/regexp-opt.el (regexp-opt-depth): Skip named groups.

* lisp/emacs-lisp/syntax.el (syntax-propertize-function)
(syntax-propertize-chunk-size, syntax-propertize--done)
(syntax-propertize-extend-region-functions): New vars.
(syntax-propertize-wholelines, syntax-propertize-multiline)
(syntax-propertize--shift-groups, syntax-propertize-via-font-lock)
(syntax-propertize): New functions.
(syntax-propertize-rules): New macro.
(syntax-ppss-flush-cache): Set syntax-propertize--done.
(syntax-ppss): Call syntax-propertize.

* lisp/progmodes/ada-mode.el (ada-set-syntax-table-properties)
(ada-after-change-function, ada-initialize-syntax-table-properties)
(ada-handle-syntax-table-properties): Only define when
syntax-propertize is not available.
(ada-mode): Use syntax-propertize-function.

* lisp/progmodes/autoconf.el (autoconf-mode):
Use syntax-propertize-function.
(autoconf-font-lock-syntactic-keywords): Remove.

* lisp/progmodes/cfengine.el (cfengine-mode):
Use syntax-propertize-function.
(cfengine-font-lock-syntactic-keywords): Remove.

* lisp/progmodes/cperl-mode.el (cperl-mode): Use syntax-propertize-function.

* lisp/progmodes/fortran.el (fortran-mode): Use syntax-propertize-function.
(fortran--font-lock-syntactic-keywords): New var.
(fortran-line-length): Update syntax-propertize-function and
fortran--font-lock-syntactic-keywords.

* lisp/progmodes/gud.el (gdb-script-syntax-propertize-function): New var;
replaces gdb-script-font-lock-syntactic-keywords.
(gdb-script-mode): Use it.

* lisp/progmodes/js.el (js--regexp-literal): Define while compiling.
(js-syntax-propertize-function): New var; replaces
js-font-lock-syntactic-keywords.
(js-mode): Use it.

* lisp/progmodes/make-mode.el (makefile-syntax-propertize-function):
New var; replaces makefile-font-lock-syntactic-keywords.
(makefile-mode): Use it.
(makefile-imake-mode): Adjust.

* lisp/progmodes/mixal-mode.el (mixal-syntax-propertize-function): New var;
replaces mixal-font-lock-syntactic-keywords.
(mixal-mode): Use it.

* lisp/progmodes/octave-mod.el (octave-syntax-propertize-sqs): New function
to replace octave-font-lock-close-quotes.
(octave-syntax-propertize-function): New function to replace
octave-font-lock-syntactic-keywords.
(octave-mode): Use it.

* lisp/progmodes/perl-mode.el (perl-syntax-propertize-function): New fun to
replace perl-font-lock-syntactic-keywords.
(perl-syntax-propertize-special-constructs): New fun to replace
perl-font-lock-special-syntactic-constructs.
(perl-font-lock-syntactic-face-function): New fun.
(perl-mode): Use it.

* lisp/progmodes/python.el (python-syntax-propertize-function): New var to
replace python-font-lock-syntactic-keywords.
(python-mode): Use it.
(python-quote-syntax): Simplify and adjust to new use.

* lisp/progmodes/ruby-mode.el (ruby-here-doc-beg-re):
Define while compiling.
(ruby-here-doc-end-re, ruby-here-doc-beg-match)
(ruby-font-lock-syntactic-keywords, ruby-comment-beg-syntax)
(syntax-ppss, ruby-in-ppss-context-p, ruby-in-here-doc-p)
(ruby-here-doc-find-end, ruby-here-doc-beg-syntax)
(ruby-here-doc-end-syntax): Only define when
syntax-propertize is not available.
(ruby-syntax-propertize-function, ruby-syntax-propertize-heredoc):
New functions.
(ruby-in-ppss-context-p): Update to new syntax of heredocs.
(electric-indent-chars): Silence bytecompiler.
(ruby-mode): Use prog-mode, syntax-propertize-function, and
electric-indent-chars.

* lisp/progmodes/sh-script.el (sh-st-symbol): Remove.
(sh-font-lock-close-heredoc, sh-font-lock-open-heredoc): Add eol arg.
(sh-font-lock-flush-syntax-ppss-cache, sh-font-lock-here-doc): Remove.
(sh-font-lock-quoted-subshell): Assume we've already matched $(.
(sh-font-lock-paren): Set syntax-multiline.
(sh-font-lock-syntactic-keywords): Remove.
(sh-syntax-propertize-function): New function to replace it.
(sh-mode): Use it.

* lisp/progmodes/simula.el (simula-syntax-propertize-function): New var to
replace simula-font-lock-syntactic-keywords.
(simula-mode): Use it.

* lisp/progmodes/tcl.el (tcl-syntax-propertize-function): New var to
replace tcl-font-lock-syntactic-keywords.
(tcl-mode): Use it.

* lisp/progmodes/vhdl-mode.el (vhdl-mode): Use syntax-propertize-function
if available.
(vhdl-fontify-buffer): Adjust.

* lisp/textmodes/bibtex.el (bibtex-mode): Use syntax-propertize-function.

* lisp/textmodes/reftex.el (font-lock-syntactic-keywords): Don't declare
since we don't use it.

* lisp/textmodes/sgml-mode.el (sgml-syntax-propertize-function): New var to
replace sgml-font-lock-syntactic-keywords.
(sgml-mode): Use it.

* lisp/textmodes/tex-mode.el (tex-common-initialization, doctex-mode):
Use syntax-propertize-function.

* lisp/textmodes/texinfo.el (texinfo-syntax-propertize-function): New fun
to replace texinfo-font-lock-syntactic-keywords.
(texinfo-mode): Use it.

* test/indent/octave.m: Remove some `fixindent' not needed any more.
2010-09-11 01:13:42 +02:00
Stefan Monnier
e17b68ed83 Use SMIE for octave-mode.
* test/indent/octave.m: New file.
* lisp/progmodes/octave-mod.el (octave-font-lock-keywords): Use regexp-opt.
(octave-mode-map): Remove special bindings for forward/backward-block
and octave-backward-up-block.  Use smie-close-block.
(octave-continuation-marker-regexp): New var.
(octave-continuation-regexp): Use it.
(octave-operator-table, octave-smie-op-levels)
(octave-operator-regexp, octave-smie-indent-rules): New vars.
(octave-smie-backward-token, octave-smie-forward-token): New funs.
(octave-mode): Use SMIE.
(octave-close-block): Delete.
2010-08-30 22:34:52 +02:00
Ulf Jasper
81ee941084 Fixed bug#6766 (icalendar.el)
lisp/ChangeLog:

	* calendar/icalendar.el (icalendar-uid-format): Doc fix.
	(icalendar--split-value): Fixed splitting regexp. (Bug#6766)
	(icalendar--get-weekday-numbers): New
	(icalendar--create-uid, icalendar-export-region)
	(icalendar--parse-summary-and-rest): Code formatting.
	(icalendar--convert-recurring-to-diary): Handle multiple byday
	values in weekly rules. (Bug#6766)

test/ChangeLog:
        
	* icalendar-testsuite.el (icalendar-testsuite-run): Added internal tests.
	(icalendar-testsuite--trim, icalendar-testsuite--compare-strings)
	(icalendar-testsuite--run-internal-tests): New.
	(icalendar-testsuite--test-convert-ordinary-to-ical)
	(icalendar-testsuite--test-convert-block-to-ical)
	(icalendar-testsuite--test-convert-anniversary-to-ical)
	(icalendar-testsuite--test-parse-vtimezone)
	(icalendar-testsuite--do-test-export): Code formatting.
	(icalendar-testsuite--test-parse-vtimezone): Doc fix.
	(icalendar-testsuite--do-test-import)
	(icalendar-testsuite--do-test-cycle): Use icalendar-testsuite--compare-strings
	(icalendar-testsuite--run-import-tests): Comment added.
	(icalendar-testsuite--run-import-tests)
	(icalendar-testsuite--run-real-world-tests): Fixed expected results.
2010-08-08 19:42:47 +02:00
Chong Yidong
71ab16dd94 Add redisplay test for image and overlay string interaction. 2010-06-24 20:33:25 -04:00
Chong Yidong
6534e58a57 Fix for comint-password-prompt-regexp (Bug#6367).
* lisp/comint.el (comint-password-prompt-regexp): Fix 2010-04-10 change
(Bug#6367).

* comint-testsuite.el: New file.
2010-06-11 10:39:54 -04:00
Stefan Monnier
927c346bd6 * lisp/emacs-lisp/smie.el (smie-indent-calculate): Simplify and cleanup.
(smie-indent-hanging-p): Use smie-bolp.
* test/indent: New dir.
2010-06-02 16:13:11 -04:00
Stefan Monnier
0235128c15 Merge from emacs-23 2010-05-08 14:47:07 -04:00
Chong Yidong
61a808e819 Bump version to 23.2. 2010-05-07 23:28:26 -04:00
Stefan Monnier
857387516c Merge from emacs-23 branch 2010-03-30 22:37:57 -04:00
Juri Linkov
dc2d2590b2 Make occur handle multi-line matches cleanly with context.
http://lists.gnu.org/archive/html/emacs-devel/2010-03/msg01280.html

* replace.el (occur-accumulate-lines): Add optional arg `pt'.
(occur-engine): Add local variables `ret', `prev-after-lines',
`prev-lines'.  Use more arguments for `occur-context-lines'.
Set first elem of its returned list to `data', and the second elem
to `prev-after-lines'.  Don't print the separator line.
In the end, print remaining context after-lines.
(occur-context-lines): Add new arguments `begpt', `endpt',
`lines', `prev-lines', `prev-after-lines'.  Rewrite to combine
after-lines of the previous match with before-lines of the
current match and not overlap them.  Return a list with two
values: the output line and the list of context after-lines.

* search.texi (Other Repeating Search): Remove line that `occur'
can not handle multiline matches.

* occur-testsuite.el (occur-tests): Add tests for context lines.
2010-03-30 19:03:08 +03:00
Chong Yidong
3cbcd186e1 Add a test function from semantic-test.el to semantic-ia-utest.el.
* cedet/semantic-ia-utest.el
(semantic-symref-test-count-hits-in-tag): Add function, from
semantic-test.el.
2010-03-29 17:35:39 -04:00
Chong Yidong
a4100ebe29 Update Semantic test copyrights, delete some test files (Bug#4656).
* cedet/tests/test.cpp:
* cedet/tests/test.py:
* cedet/tests/teststruct.cpp:
* cedet/tests/testtemplates.cpp:
* cedet/tests/testusing.cpp:
* cedet/tests/scopetest.cpp:
* cedet/tests/scopetest.java: Files deleted.

* cedet/tests/test.make:
* cedet/tests/test.c:
* cedet/tests/testjavacomp.java:
* cedet/tests/testspp.c:
* cedet/tests/testsppreplace.c:
* cedet/tests/testsppreplaced.c:
* cedet/tests/testsubclass.cpp:
* cedet/tests/testsubclass.hh:
* cedet/tests/testtypedefs.cpp:
* cedet/tests/testvarnames.c:
* cedet/tests/test.el:
* cedet/tests/testdoublens.cpp:
* cedet/tests/testdoublens.hpp: Add copyright header.

* cedet/semantic-tests.el (semanticdb-test-gnu-global): Remove
reference to deleted files.
2010-03-29 17:26:49 -04:00
Stefan Monnier
e867cb5d30 Merge from `emacs-23'. 2010-03-24 14:02:56 -04:00
Juri Linkov
5275ff8b1f * occur-testsuite.el: New file. 2010-03-23 18:18:52 +02:00
Glenn Morris
c7415cfc45 License updates for some test/cedet/tests files.
* testjavacomp.java, testpolymorph.cpp: Convert copyright of author
with assignment to FSF copyright.  Add 2010.  Relicense under GPLv3+.
2010-03-10 22:58:54 -08:00
Chong Yidong
288f9fc069 Bump version to 24.0.50. 2010-03-10 10:17:13 -05:00
Glenn Morris
2c21a6e282 Add license information for ede-test.el and srecode-test.el.
The information is based on the files in cedet from which these
files were extracted (see commentaries).
2010-03-05 19:00:40 -08:00
Ulf Jasper
b4340b3f0b Fixed bug#5549 (icalendar.el) 2010-02-19 19:59:00 +01:00
Juanma Barranquero
db9e401b3b Fix typos in docstrings, error messages, etc. 2010-01-18 05:39:40 +01:00
Juanma Barranquero
d1f18ec092 Fix typos in docstrings. 2010-01-14 19:59:31 +01:00
Glenn Morris
114f9c9679 Add 2010 to copyright years. 2010-01-13 00:35:10 -08:00
Ulf Jasper
6fe539d246 Fixed timezone handling problem in icalendar.el. 2009-12-18 19:35:14 +00:00
Miles Bader
d356f4fcff Remove RCS keywords
Revision: emacs@sv.gnu.org/emacs--devo--0--patch-1642
2009-12-11 20:48:03 +00:00
Miles Bader
3999968a73 Add arch tagline 2009-10-02 10:53:34 +00:00
Glenn Morris
d8085053bb Relicense under GPLv3+. 2009-09-30 02:28:17 +00:00
Chong Yidong
7c4dccd032 * cedet/*: New unit tests, from CEDET repository. 2009-09-28 23:24:55 +00:00
Chong Yidong
74ea13c1a8 Add CEDET tests. 2009-09-28 23:23:31 +00:00
Chong Yidong
0d55afa049 Mention etc/compilation.txt 2009-07-26 15:59:37 +00:00
Juri Linkov
6d361d9941 Fix comment. 2009-07-02 22:50:07 +00:00
Miles Bader
c5c194aa92 Add arch tagline 2009-07-02 10:38:05 +00:00
Chong Yidong
6ada5ad143 * redisplay-testsuite.el: New file. 2009-06-26 14:42:43 +00:00
Chong Yidong
7024347875 Add "Branch for 23.1" ChangeLog entry. 2009-06-21 14:35:26 +00:00
Ulf Jasper
f052351afe icalendar: uid-format, bug fixes. 2009-01-25 13:38:14 +00:00
Glenn Morris
21b6f58f55 Add 2009 to copyright years. 2009-01-08 02:56:31 +00:00
Juanma Barranquero
d483550724 Fix typos. 2008-12-17 15:25:54 +00:00
Miles Bader
78ca4710c5 Add arch tagline 2008-12-01 02:27:55 +00:00
Chong Yidong
835404e5fd New file. 2008-11-30 05:57:33 +00:00
Chong Yidong
dee5aa9105 * bytecomp-testsuite.el: New file, 2008-11-30 05:57:19 +00:00
Ulf Jasper
aad81014a9 icalendar: uid-creation improved 2008-10-31 18:48:23 +00:00
Miles Bader
5a88dbb600 Add arch tagline 2008-06-15 06:31:29 +00:00
Ulf Jasper
d176d8c6e8 Added newsticker-testsuite.el. 2008-06-14 10:11:20 +00:00
Glenn Morris
a4766629f8 Ulf Jasper <ulf.jasper at web.de>
(icalendar-testsuite--run-function-tests):
Add icalendar-testsuite--test-datestring-to-isodate,
icalendar-testsuite--test-datetime-to-diary-date, and
icalendar-testsuite--test-calendar-style.
(icalendar-testsuite--test-format-ical-event):
(icalendar-testsuite--test-parse-summary-and-rest): Doc fix.
Remove european-calendar-style.
(icalendar-testsuite--get-ical-event): Doc fix.
(icalendar-testsuite--test-first-weekday-of-year):
(icalendar-testsuite--run-cycle-tests): Add doc string.
(icalendar-testsuite--test-datestring-to-isodate):
(icalendar-testsuite--test-datetime-to-diary-date):
(icalendar-testsuite--test-calendar-style): New functions.
(icalendar-testsuite--test-export): Handle iso date style.
New arg INPUT-ISO.  Use calendar-date-style.
(icalendar-testsuite--test-import): Handle iso date style.
New arg EXPECTED-ISO.  Use calendar-date-style.
(icalendar-testsuite--test-cycle): Handle iso date style.
(icalendar-testsuite--run-import-tests):
(icalendar-testsuite--run-export-tests):
(icalendar-testsuite--run-real-world-tests): Add iso style tests.
2008-05-24 02:25:03 +00:00
Glenn Morris
4f43e9371b Switch to recommended form of GPLv3 permissions notice. 2008-05-07 07:27:10 +00:00
Kenichi Handa
880820fe87 (Fdefine_charset_internal): Change the way of
registering charsets in Vcharset_order_list.
(syms_of_charset): Make the charset `eight-bit' supplementary.
2008-03-27 11:36:43 +00:00
Glenn Morris
e42fc90537 *** empty log message *** 2008-02-29 07:55:05 +00:00
Glenn Morris
7ec0153248 Ulf Jasper <ulf.jasper at web.de>: New file. 2008-02-29 04:27:44 +00:00
Glenn Morris
366b88a229 New file. 2008-02-29 04:27:23 +00:00