1. 28 Oct, 2015 1 commit
    • Juanma Barranquero's avatar
      Fix bug#21766 and add test · 1f02cbea
      Juanma Barranquero authored
      * lisp/simple.el (delete-trailing-whitespace): Save match data when
      calling `skip-syntax-backward'.
      * test/automated/simple-test.el (simple-delete-trailing-whitespace):
      New test.
      1f02cbea
  2. 27 Oct, 2015 3 commits
  3. 26 Oct, 2015 3 commits
    • Eli Zaretskii's avatar
      Fix simple-test.el test · c9fb8954
      Eli Zaretskii authored
      * test/automated/simple-test.el (simple-test--dummy-buffer): Make
      sure indentation doesn't use TABs, otherwise the 6th test might
      fail.
      c9fb8954
    • Michael Albinus's avatar
      Further work on `stopped' events in filenotify.el · 0d9c6723
      Michael Albinus authored
      * doc/lispref/os.texi (File Notifications): Rework examples.
      
      * lisp/filenotify.el (file-notify--rm-descriptor): Optional parameter.
      (file-notify--rm-descriptor, file-notify-callback): Improve check
      for sending `stopped' event.
      (file-notify-add-watch): Check for more events for `inotify'.
      
      * test/automated/file-notify-tests.el
      (file-notify--test-expected-events): New defvar.
      (file-notify--test-with-events): Use it.
      (file-notify--test-cleanup): Make it more robust when deleting
      directories.
      (file-notify--test-event-test): Check also for watched directories.
      (file-notify--test-event-handler): Suppress temporary .#files.
      (file-notify-test02-events, file-notify-test04-file-validity):
      Rework `stopped' events.
      (file-notify-test05-dir-validity): Wait for events when appropriate.
      0d9c6723
    • Artur Malabarba's avatar
      * test/automated/simple-test.el: New file · 207f235e
      Artur Malabarba authored
      Define tests for `newline' and `open-line'.
      207f235e
  4. 25 Oct, 2015 1 commit
    • Michael Albinus's avatar
      Introduce `stopped' event in file notification · ab116b19
      Michael Albinus authored
      * lisp/filenotify.el (file-notify--rm-descriptor): New defun.
      (file-notify-rm-watch): Use it.
      (file-notify-callback): Implement `stopped' event.
      (file-notify-add-watch): Mention `stopped' in the docstring.
      Check, that upper directory exists.
      
      * test/automated/file-notify-tests.el (file-notify-test01-add-watch):
      Add two test cases.
      (file-notify-test02-events): Handle also `stopped' event.
      (file-notify-test04-file-validity): Add another test case.
      ab116b19
  5. 23 Oct, 2015 2 commits
    • NicolasPetton's avatar
      New library thunk.el · 0f443a12
      NicolasPetton authored
      thunk.el is extracted from stream.el in ELPA, with additional tests.
      
      * lisp/emacs-lisp/thunk.el: New file.
      * test/automated/thunk-tests.el: New file.
      * etc/NEWS: Add information about thunk.el
      0f443a12
    • Michael Albinus's avatar
      Fix Bug#21669 · 71d6acff
      Michael Albinus authored
      * lisp/filenotify.el (file-notify-rm-watch): Improve check for
      calling low-level functions.
      
      * test/automated/file-notify-tests.el (file-notify--test-timeout):
      Decrase to 6 seconds for remote directories.
      (file-notify-test02-events): Expect different number of
      `attribute-changed' events for the local and remote cases.  Apply
      short delays between the operations, in order to receive all
      events in the remote case.  Combine `attribute-change' tests.
      (Bug#21669)
      71d6acff
  6. 19 Oct, 2015 1 commit
    • NicolasPetton's avatar
      New function seq-position · 04d604e0
      NicolasPetton authored
      * lisp/emacs-lisp/seq.el (seq-position): New function.
      * test/automated/seq-tests.el: New tests for seq-position.
      * doc/lispref/sequences.texi: Add documentation for `seq-position'.
      04d604e0
  7. 17 Oct, 2015 1 commit
  8. 15 Oct, 2015 1 commit
  9. 14 Oct, 2015 1 commit
    • Paul Eggert's avatar
      Spelling fixes · 943f7f90
      Paul Eggert authored
      * configure.ac (bitmapdir): Fix misspelling of bmd_acc.
      * test/automated/coding-tests.el (ert-test-coding-bogus-coding-systems):
      Fix misspelling of nonexistent file name.
      943f7f90
  10. 13 Oct, 2015 1 commit
  11. 11 Oct, 2015 1 commit
    • Paul Eggert's avatar
      Use ‘echo’ safely with ‘\’ or leading ‘-’ · 29dfca23
      Paul Eggert authored
      POSIX says that ‘echo FOO’ produces implementation-defined output
      if FOO contains leading ‘-’, or ‘\’ anywhere, so don’t assume GNU
      behavior in that case.
      * Makefile.in (removenullpaths): Remove.
      (epaths-force): Rewrite to avoid the need for ‘echo’.
      (install-etc): Be clearer about escaping the shell metacharacters
      ‘\’ and ‘$’.
      * Makefile.in (install-arch-indep, install-etcdoc):
      * admin/charsets/mapconv, admin/merge-gnulib, admin/merge-pkg-config:
      * admin/quick-install-emacs, build-aux/gitlog-to-emacslog:
      * configure.ac, lib-src/rcs2log, make-dist:
      * src/Makefile.in (lisp.mk):
      Don’t assume ‘echo’ outputs ‘\’ and leading ‘-’ unscathed.
      For example, use ‘printf '%s\n' "$foo"’ rather than ‘echo "$foo"’
      if $foo can contain arbitrary characters.
      * lisp/Makefile.in (TAGS): Use ‘ls’, not ‘echo’, to avoid ‘\’ issues.
      * doc/lispref/two-volume.make (vol1.pdf):
      * test/etags/make-src/Makefile (web ftp publish):
      Use ‘printf’ rather than ‘echo -e’.
      29dfca23
  12. 07 Oct, 2015 2 commits
  13. 06 Oct, 2015 1 commit
  14. 05 Oct, 2015 1 commit
  15. 04 Oct, 2015 1 commit
  16. 03 Oct, 2015 1 commit
    • Simen Heggestøyl's avatar
      Maintain ordering of JSON object keys by default · 6b663751
      Simen Heggestøyl authored
      * lisp/json.el (json-object-type): Mention order handling in doc-string.
      (json--plist-reverse): New utility function.
      (json-read-object): Maintain ordering for alists and plists.
      (json-pretty-print): Ensure that ordering is maintained.
      
      * test/automated/json-tests.el (test-json-plist-reverse): New test for
      `json--plist-reverse'.
      (json-read-simple-alist): Update test to accommodate for changes in
      `json-read-object'.
      
      * etc/NEWS: Document the new behavior of the pretty printing functions.
      6b663751
  17. 30 Sep, 2015 1 commit
  18. 29 Sep, 2015 1 commit
    • Stefan Monnier's avatar
      * lisp/progmodes/octave.el: Use grammar more; Handle enumeration fun · 90a6f8d0
      Stefan Monnier authored
      Remove redundant :group keyword args.
      (octave-begin-keywords, octave-else-keywords, octave-end-keywords):
      Remove variables.
      (octave-operator-table, octave-smie-bnf-table): Use let-when-compile to
      turn them into compile-time variables.
      Auto-generate the "foo ... end" rules from the "foo ... endfoo" rules.
      Add rules for break, continue, return, global, and persistent.
      Refine the rule for "until".
      (octave-smie--funcall-p, octave-smie--end-index-p)
      (octave-smie--in-parens-p): New functions.
      (octave-smie-backward-token, octave-smie-forward-token): Use them to
      distinguish the "enumeration" function and the "end" index from
      their corresponding keywords.
      (octave--block-offset-keywords): New constant.
      (octave-smie-rules): Use it.  Adjust rules for new global/persistent parsing.
      (octave-reserved-words): Redefine using octave-smie-grammar.
      (octave-font-lock-keywords): Use octave-smie--funcall-p and
      octave-smie--end-index-p.
      90a6f8d0
  19. 28 Sep, 2015 1 commit
  20. 23 Sep, 2015 1 commit
  21. 22 Sep, 2015 1 commit
    • Stefan Monnier's avatar
      * prolog.el: Fix indentation of empty line · 6c33e7ad
      Stefan Monnier authored
      * lisp/emacs-lisp/smie.el (smie-rules-function): Document new
      `empty-line-token' element.
      (smie-indent-empty-line): New function.
      (smie-indent-functions): Add it.
      
      * lisp/progmodes/prolog.el (prolog-smie-rules): Fix :list-intro behavior
      and use the new `empty-line-token' element (bug#21526).
      (prolog-mode-variables): Fix comment-start-skip setting to match
      comment-start.
      
      * test/indent/prolog.prolog: Add nested indentation tests.
      
      * lisp/newcomment.el (comment-normalize-vars): Fix default value of
      comment-start-skip not to misuse submatch 1.
      6c33e7ad
  22. 21 Sep, 2015 3 commits
    • Eli Zaretskii's avatar
      Another fix of file-notify-tests for w32notify · d443345b
      Eli Zaretskii authored
      * test/automated/file-notify-tests.el (file-notify-test02-events):
      Further adaptation for w32notify: reduce the number of expected
      'changed' events.  (Bug#21435)
      d443345b
    • Michael Albinus's avatar
      Adapt tests and manual for w32notify · 01b54752
      Michael Albinus authored
      * doc/lispref/os.texi (File Notifications): w32notify does not
      send `attribute-changed' events.
      
      * test/automated/file-notify-tests.el (file-notify--test-with-events):
      Simplify parameters.  Adapt all callees.
      (file-notify-test02-events): w32notify does not send
      `attribute-changed' events.
      (file-notify-test04-file-validity, file-notify-test05-dir-validity):
      Do not skip in case of w32notify.  Simply ignore this part of the test.
      01b54752
    • Stefan Monnier's avatar
      Subject: * lisp/progmodes/prolog.el: Improve handling of if/then/else · 57d48c36
      Stefan Monnier authored
      (prolog-smie-rules): Accomodate standard if/then/else special indentation.
      (prolog-mode): Add . to electric-indent-chars.
      (prolog-electric--if-then-else): Re-indent the line before adding space
      after the new char (bug#21526).
      57d48c36
  23. 20 Sep, 2015 1 commit
    • Michael Albinus's avatar
      Improve file notifications, especially for Tramp · f5bdcb32
      Michael Albinus authored
      * doc/lispref/files.texi (Magic File Names):
      Mention `file-notify-valid-p'.
      
      * doc/lispref/os.texi (File Notifications):
      Describe `file-notify-valid-p'.
      
      * etc/NEWS: Add `file-notify-valid-p'.
      
      * lisp/net/tramp-gvfs.el (tramp-gvfs-handle-file-notify-add-watch):
      Improve implementation.
      (tramp-gvfs-monitor-file-process-filter): Rename from
      `tramp-gvfs-file-gvfs-monitor-file-process-filter'.  Delete
      process if appropriate.
      
      * lisp/net/tramp-sh.el (tramp-sh-handle-file-notify-add-watch):
      Improve implementation.
      (tramp-sh-gvfs-monitor-dir-process-filter): Rename from
      `tramp-sh-file-gvfs-monitor-dir-process-filter'.  Delete process
      if appropriate.
      (tramp-sh-inotifywait-process-filter): Rename from
      `tramp-sh-file-inotifywait-process-filter'.  Delete process if
      appropriate.
      
      * lisp/net/tramp.el (tramp-handle-file-notify-rm-watch):
      Use `delete-process'
      (tramp-handle-file-notify-valid-p): Check also, that file or
      directory to be watched still exists.
      
      * test/automated/file-notify-tests.el (file-notify--test-timeout):
      New defun.  Use it at all places a timeout is needed.
      (file-notify--test-cleanup): Delete directories recursively.
      Cleanup also Tramp connections.
      (file-notify-test02-events): Add tests for `attribute-change'.
      (file-notify-test04-file-validity, file-notify-test05-dir-validity):
      Add tests for `file-notify-rm-watch'.
      f5bdcb32
  24. 17 Sep, 2015 2 commits
    • Paul Eggert's avatar
      Backslash cleanup in Elisp source files · 284c470e
      Paul Eggert authored
      This patch should not change behavior.  It typically omits backslashes
      where they are redundant (e.g., in the string literal "^\$").
      In a few places, insert backslashes where they make regular
      expressions clearer: e.g., replace "^\*" (equivalent to "^*") with
      "^\\*", which has the same effect as a regular expression.
      Also, use ‘\ %’ instead of ‘\%’ when avoiding confusion with SCCS IDs,
      and similarly use ‘\ $’ instead of ‘\$’ when avoiding confusion with
      RCS IDs, as that makes it clearer that the backslash is intended.
      284c470e
    • Paul Eggert's avatar
      Some more minor backslash fixes · d149ff52
      Paul Eggert authored
      * test/automated/compile-tests.el (compile-tests--test-regexps-data):
      * test/automated/info-xref.el (info-xref-test-write-file):
      Double backslashes in strings.
      d149ff52
  25. 16 Sep, 2015 3 commits
  26. 15 Sep, 2015 3 commits
    • Stephen Leake's avatar
      Fix a bug in elisp--xref-find-definitions related to cl-generic defaults · 711a8eec
      Stephen Leake authored
      * lisp/progmodes/elisp-mode.el (elisp--xref-find-definitions): Fix bug
      with cl-generic defaults.
      (elisp--xref-find-references): Add doc string.
      
      * test/automated/elisp-mode-tests.el (xref-elisp-generic-*): Improve
      tests to find bug.
      711a8eec
    • Michael Albinus's avatar
      Adapt tests in auto-revert-tests.el · 5c182636
      Michael Albinus authored
      * test/automated/auto-revert-tests.el (auto-revert--timeout):
      Make it a defconst.
      (auto-revert--wait-for-revert): New defun.
      (auto-revert-test00-auto-revert-mode)
      (auto-revert-test01-auto-revert-tail-mode)
      (auto-revert-test02-auto-revert-mode-dired): Use it.
      5c182636
    • Eli Zaretskii's avatar
      Fix the file-notify tests for watch validation on w32 · 20b177d5
      Eli Zaretskii authored
      * test/automated/file-notify-tests.el
      (file-notify-test04-file-validity): Move the directory deletion
      out of the file-notify--test-with-events macro.
      (file-notify-test04-file-validity)
      (file-notify-test05-dir-validity): Enlarge the timeout of
      read-event to 0.5, as 0.1 is borderline on w32.  (Bug#21432)
      20b177d5
  27. 14 Sep, 2015 1 commit
    • Michael Albinus's avatar
      Adaot file-notify-tests.el test cases · 67ddc7c5
      Michael Albinus authored
      * lisp/filenotify.el (file-notify-rm-watch): Ignore `file-notify-error'.
      
      * src/inotify.c (Finotify_valid_p): Adapt docstring.
      
      * test/automated/file-notify-tests.el ()
      (file-notify-test03-autorevert)
      (file-notify-test04-file-validity)
      (file-notify-test04-file-validity-remote)
      (file-notify-test05-dir-validity)
      (file-notify-test05-dir-validity-remote): Adapt docstring.
      (file-notify-test04-file-validity): Let events arrive before
      calling final `file-notify-valid-p'.  Do not ignore errors.
      (file-notify-test05-dir-validity): Do not manipulate
      `temporary-file-directory', it isn't necessary.  Let events arrive
      before calling final `file-notify-valid-p'.  Do not ignore errors.
      67ddc7c5