summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp
Commit message (Collapse)AuthorAgeFilesLines
...
* | Simplify cl-get using `plist-member'Noam Postavsky2017-02-201-20/+8
| | | | | | | | | | | | * lisp/emacs-lisp/cl-extra.el (cl-get, cl-getf, cl--set-getf): Use `plist-member' instead of explicit loop. * test/lisp/emacs-lisp/cl-extra-tests.el: New tests.
* | Turn on lexical-binding in elint.elMark Oteiza2017-02-171-9/+7
| | | | | | | | | | | | | | | | * lisp/emacs-lisp/elint.el: Quote entry point commands in commentary. (elint-running, elint-current-pos): Move these dynamic vars to toward the top of the file. (elint-check-quote-form): Ignore unused argument. (elint-check-conditional-form): Remove unused binding.
* | * lisp/emacs-lisp/subr-x.el (if-let*): Fix Edebug spec (Bug#24748)Gemini Lasswell2017-02-171-1/+2
| |
* | ; Spelling, punctuation and minor wording fixesPaul Eggert2017-02-162-4/+4
| |
* | bytecomp.el: Avoid unnecessary calculation for jump table addresses.Vibhav Pant2017-02-161-2/+7
| | | | | | | | | | | | * lisp/emacs-lisp/bytecomp.el (byte-compile-lapcode): Don't do redundant operations while calculating the correct jump addresses from TAGs in jump tables.
* | Don't expand body inside a let-binding when there are no bindingsMark Oteiza2017-02-151-2/+4
| | | | | | | | | | * lisp/emacs-lisp/pcase.el (pcase-codegen): Only let-bind if VARS is non-nil.
* | byte-opt: Replace merged tags in jump tables too. (bug#25716)Vibhav Pant2017-02-141-1/+11
| | | | | | | | | | | | | | | | * lisp/emacs-lisp/byte-opt.el (byte-optimize-lapcode): While merging adjacent tags, make sure that the old tag is replaced in all jump tables, if any. This fixes the bytecode VM jumping to the wrong address in compiled cond forms where the body of a clause was a loop of any sort.
* | Merge branch 'master' into feature/byte-switchVibhav Pant2017-02-134-11/+11
|\ \
| * | Nix some useless uses of looking-at, looking-backMark Oteiza2017-02-124-11/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/allout.el (allout-kill-topic): (allout-next-topic-pending-encryption): * lisp/bookmark.el (bookmark-kill-line): * lisp/cus-edit.el (custom-save-variables, custom-save-faces): * lisp/cus-theme.el (custom-theme-write-variables): (custom-theme-write-faces): * lisp/emacs-lisp/autoload.el (autoload-generate-file-autoloads): * lisp/emacs-lisp/bytecomp.el (byte-compile-from-buffer): * lisp/emacs-lisp/checkdoc.el (checkdoc-interactive-loop): (checkdoc-interactive-ispell-loop): (checkdoc-message-interactive-ispell-loop, checkdoc-this-string-valid): (checkdoc-this-string-valid-engine): * lisp/emacs-lisp/elint.el (elint-get-top-forms): * lisp/emulation/viper-cmd.el (viper-backward-indent): * lisp/image-dired.el (image-dired-delete-char): * lisp/simple.el (kill-visual-line): Replace instances of looking-at, looking-back with char comparisons using following-char, preceding-char.
* | | ; Add more documentation for byte-switch related code.Vibhav Pant2017-02-132-3/+13
| | |
* | | ; lisp/emacs-lisp/bytecomp.el: Fix indentation.Vibhav Pant2017-02-121-1/+1
| | |
* | | Merge branch 'master' into feature/byte-switchVibhav Pant2017-02-111-4/+2
|\| |
| * | Fix instrumenting code with propertized strings in EdebugGemini Lasswell2017-02-101-4/+2
| | | | | | | | | | | | | | | * lisp/emacs-lisp/edebug.el (edebug-read-function): Allow 'read' to decide what is and isn't a syntax error. (Bug#25068)
* | | Improve byte-switch execution.Vibhav Pant2017-02-092-7/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/byte-opt.el, lisp/emacs-lisp/bytecomp.el (byte-decompile-bytecode-1), (byte-compile-lapcode): Calculate the actual jump address while compiling, store it in the jump table. * src/bytecode.c: Jump to the looked up value directly, do a linear search when the number of elements is <= 5.
* | | ; bytecomp.el (byte-compile-cond-jump-table): Add TODO noteVibhav Pant2017-02-061-0/+2
| | |
* | | ; byte(-opt, comp).el: Add more documentation for byte-switch code.Vibhav Pant2017-02-062-0/+22
| | |
* | | Merge remote-tracking branch 'origin/master' into feature/byte-switchVibhav Pant2017-02-055-16/+69
|\| |
| * | New macro 'ert-with-message-capture'Gemini Lasswell2017-02-041-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/ert-x.el (ert-with-message-capture): New macro. (Bug#25158) * test/lisp/autorevert-tests.el (auto-revert--wait-for-revert) (auto-revert-test00-auto-revert-mode) (auto-revert-test01-auto-revert-several-files) (auto-revert-test02-auto-revert-deleted-file) (auto-revert-test03-auto-revert-tail-mode) (auto-revert-test04-auto-revert-mode-dired): * test/lisp/filenotify-tests.el (file-notify-test03-autorevert): Use ert-with-message-capture.
| * | Avoid invalid read syntax errors due to 'ert-with-test-buffer'Gemini Lasswell2017-02-041-1/+1
| | | | | | | | | | | | | | | * lisp/emacs-lisp/ert-x.el (ert-with-test-buffer): Fix the 'declare' form. (Bug#24722)
| * | Fix a syntax error when evaluating pcase.el under EdebugEli Zaretskii2017-02-041-1/+2
| | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/pcase.el (pcase-MACRO): Replace def-edebug-spec with an explicit 'put' form. Suggested by Gemini Lasswell <gazally@runbox.com>. (Bug#24717)
| * | Change edebug-max-depth from defconst to defcustomGemini Lasswell2017-02-041-1/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/edebug.el (edebug-max-depth): Add defcustom. (Bug#24713) * etc/NEWS: Mention edebug-max-depth. * doc/lispref/edebug.texi (Checking Whether to Stop): Mention edebug-max-depth and index it. Add cross-references for max-lisp-eval-depth and max-specpdl-size. Co-authored-by: Eli Zaretskii <eliz@gnu.org>
| * | Rename to if-let* and when-let*Mark Oteiza2017-02-031-12/+24
| | | | | | | | | | | | | | | | | | | | | Make the existing if-let and when-let aliases. * lisp/emacs-lisp/subr-x.el (if-let*, when-let*): New macros. Rewrite docstrings, incorporating that from let* and the existing if-let. (if-let, when-let, and-let*): Alias them.
| * | ; Bump let-alistMark Oteiza2017-01-311-1/+1
| | | | | | | | | | | | * lisp/emacs-lisp/let-alist.el: Bump micro version (bug#24641).
| * | read-multiple-choice: explain dialog popups moreTed Zlatanov2017-01-311-0/+5
| | | | | | | | | | | | | | | * lisp/emacs-lisp/subr-x.el (read-multiple-choice): Explain when a graphical popup is used and how it can be avoided.
| * | Revert two accidental commitsDima Kogan2017-01-311-54/+0
| | | | | | | | | | | | | | | This reverts commit f3c77d11af65f3b319b1784b4c3cf08c51aa7997. This reverts commit 3c941b900007c9e79c00af0f21d88154f6d8af1a.
| * | stashDima Kogan2017-01-301-0/+54
| | |
* | | bytecomp.el: Use macroexp-const-p instead of bc-cond-valid-obj2-p.Vibhav Pant2017-02-051-11/+5
| | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/bytecomp.el (byte-compile-cond-vars): Use (macroexp-cons-p) instead of (byte-compile-cond-valid-obj2-p) to make sure that obj1/obj2 can be compared with `eq'.
* | | * byte-opt.el (byte-decompile-bytecode-1): Use eq instead of =.Vibhav Pant2017-02-051-1/+1
| | |
* | | ; Fix typo.Vibhav Pant2017-02-051-1/+1
| | | | | | | | | | | | | | | * lisp/emacs-lisp/bytecomp.el (byte-compile-cond-jump-table-info): Fix typo in docstring.
* | | ; bytecomp.el (-inline-lapcode): Fix incorrect parenthesis, refactorVibhav Pant2017-02-051-5/+5
| | |
* | | bytecomp.el: Inline lapcode containing `byte-switch' correctly.Vibhav Pant2017-02-051-4/+35
| | | | | | | | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/bytecomp.el (byte-compile-inline-lapcode): Restore value of byte-compile-depth after emitting a jump to a tag in a jump table, or default/done tags. Set the depth of final tags for byte-switch to nil after emitting any jumps to them.
* | | ; * byte-opt.el (byte-decompile-bytecode-1): Add more documentation.Vibhav Pant2017-02-051-1/+3
| | |
* | | byte-opt.el: Replace jump tables while decompiling correctly.Vibhav Pant2017-02-051-17/+22
| | | | | | | | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/byte-opt.el (byte-decompile-bytecode-1): Don't make a copy of the constant vector, as it isn't used with the decompiled lapcode. Make sure that the correct lapcode pair/list is being modified while replacing the jump table.
* | | bytecomp.el: Don't store non-keyword symbols in jump-tables.Vibhav Pant2017-02-051-5/+7
| | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/bytecomp.el (byte-compile-cond-valid-obj2-p) return nil when OBJ is a non-keyword symbol (i.e a variable), as the jump table can only be used when comparing variables with constant values.
* | | Revert "Use maphash instead of cl-loop."Vibhav Pant2017-02-031-4/+4
| | | | | | | | | | | | This reverts commit bfa88520136dd6b187ba101e6db5a5f8f0d5e874.
* | | Use maphash instead of cl-loop.Vibhav Pant2017-02-011-4/+4
| | | | | | | | | | | | | | | * lisp/emacs-lisp/bytecomp.el: (byte-compile-lapcode) Use maphash instead of cl-loop
* | | * lisp/emacs-lisp/bytecomp.el: Create jump tables with :purecopy tVibhav Pant2017-01-301-0/+1
| | |
* | | Merge remote-tracking branch 'origin/master' into feature/byte-switchVibhav Pant2017-01-306-152/+51
|\| |
| * | Don't warn about obsolete defgenerics when defining themNoam Postavsky2017-01-291-7/+8
| | | | | | | | | | | | | | | * lisp/emacs-lisp/cl-generic.el (cl-defgeneric): The declaration code should run after the definition code (Bug#25556).
| * | Move cXXXr and cXXXXr to subr.elMark Oteiza2017-01-252-143/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * etc/NEWS: Mention new core Elisp. * doc/lispref/lists.texi (List Elements): Document and index the new functions. * doc/misc/cl.texi (List Functions): Change "defines" to "aliases". * lisp/subr.el (caaar, caadr, cadar, caddr, cdaar, cdadr, cddar) (cdddr, caaaar caaadr, caadar, caaddr, cadaar, cadadr, caddar): (cadddr, cdaaar, cdaadr, cdadar, cdaddr, cddaar, cddadr, cdddar): (cddddr): New functions. * lisp/emacs-lisp/cl-lib.el (cl-caaar, cl-caadr, cl-cadar, cl-caddr): (cl-cdaar, cl-cdadr, cl-cddar cl-cdddr, cl-caaaar cl-caaadr): (cl-caadar, cl-caaddr, cl-cadaar, cl-cadadr, cl-caddar, cl-cadddr): (cl-cdaaar, cl-cdaadr, cl-cdadar, cl-cdaddr, cl-cddaar, cl-cddadr): (cl-cdddar, cl-cddddr): Alias to new subr functions. * lisp/emacs-lisp/cl.el (cl-unload-function): Remove cXXXr and cXXXXr elements.
| * | Give , and .@ doc strings. Fixes bug #24561.Alan Mackenzie2017-01-231-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also make *Help* links to ``' possible. Also make usable as such doc strings on the function-documentation property of a symbol. * lisp/emacs-lisp/backquote.el (top-level): Give , and '@ doc strings on the function-documentation property. Also give these symbols a reader-construct property. * lisp/help-fns.el (describe-function): Allow the function-documentation property to work. Use princ rather than prin1 to print the function's name when it has a reader-construct property. (help-fns-signature): Don't insert `high-usage' for a reader-construct. (describe-function-1): Adapt to process documentation on the function-documentation property. Print "a reader construct" when appropriate. * lisp/help-mode.el (help-xref-symbol-regexp): Amend this regexp also to match ``'.
| * | Prevent to use tabulated-list--near-rows unboundTino Calancha2017-01-221-2/+7
| | | | | | | | | | | | | | | * lisp/emacs-lisp/tabulated-list.el (tabulated-list-print-entry): Make sure 'tabulated-list--near-rows' is bound before use it (Bug#25506).
| * | Fix free var FOO-mode-{syntax,abbrev}-table warningsNoam Postavsky2017-01-191-0/+2
| | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/derived.el (define-derived-mode): Unconditionally defvar the syntax and abbrev tables so that the compiler will know that they are dynamically bound variables (Bug#25446).
* | | * lisp/emacs-lisp/bytecomp.el:(bc-cond-jump-table-info)add docstringVibhav Pant2017-01-261-0/+7
| | |
* | | * lisp/emacs-lisp/bytecomp.el: Use correct function to push nilVibhav Pant2017-01-261-1/+1
| | | | | | | | | | | | | | | * lisp/emacs-lisp/bytecomp.el: (byte-compile-cond-jump-table) Use byte-compile-constant instead of byte-compile-form to push nil.
* | | * lisp/emacs-lisp/disass.el: Fix spacing while showing jump tablesVibhav Pant2017-01-261-4/+8
| | |
* | | * lisp/emacs-lisp/disass.el: Display jump tables for switch.Vibhav Pant2017-01-261-3/+11
| | |
* | | * lisp/emacs-lisp/bytecomp.el:Use correct size for switch jump-tableVibhav Pant2017-01-261-1/+4
| | |
* | | * lisp/emacs-lisp/bytecomp.el: Simplify b-c-cond-valid-obj2-pVibhav Pant2017-01-261-5/+5
| | |
* | | * lisp/emacs-lisp/bytecomp.el: Fix byte-switch codegen with symbols.Vibhav Pant2017-01-261-1/+1
| | |