summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp
Commit message (Collapse)AuthorAgeFilesLines
* * lisp/subr.el (apply-partially): Use a non-nil static environment.Stefan Monnier2011-03-301-1/+2
| | | | | | | | (--dolist-tail--, --dotimes-limit--): Don't declare dynamically bound. (dolist): Use a more efficient form for lexical-binding. (dotimes): Use a cleaner semantics for lexical-binding. * lisp/emacs-lisp/edebug.el (edebug-eval-top-level-form): Use eval-sexp-add-defvars.
* Fix C-M-x in lexbind mode. Misc tweaks.Stefan Monnier2011-03-244-4/+29
| | | | | | | | | | | | * lisp/startup.el: Convert to lexical-binding. Mark unused arguments. (command-line-1): Get rid of the "cl1-" prefix now that we use lexical scoping instead. * lisp/emacs-lisp/float-sup.el (pi): Leave it lexically scoped. * lisp/emacs-lisp/lisp-mode.el (eval-sexp-add-defvars): New fun. (eval-last-sexp-1): Use eval-sexp-add-defvars. * lisp/emacs-lisp/edebug.el (edebug-eval-defun): Use eval-sexp-add-defvars. * lisp/emacs-lisp/cconv.el (cconv--analyse-function): Fix `report-error/log-warning' mixup.
* Clean up left over Emacs-18/19 code, inline byte-code-functions.Stefan Monnier2011-03-223-245/+180
| | | | | | | | | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/byte-opt.el (byte-inline-lapcode): Move to bytecomp.el. (byte-compile-inline-expand): Inline all bytecompiled functions. Unify the inlining code of the lexbind and dynbind interpreted functions. (byte-compile-unfold-lambda): Don't handle byte-compiled functions at all. (byte-optimize-form-code-walker): Don't optimize byte-compiled inlined functions here. (byte-compile-splice-in-already-compiled-code): Remove. (byte-code): Don't optimize it any more. (byte-decompile-bytecode-1): Remove unused bytedecomp-bytes. Leave `byte-return's even for `make-spliceable'. * lisp/emacs-lisp/bytecomp.el (byte-compile-file-form-defmumble): byte-compile-lambda now always returns a byte-code-function. (byte-compile-byte-code-maker, byte-compile-byte-code-unmake) (byte-compile-closure): Remove. (byte-compile-lambda): Always return a byte-code-function. (byte-compile-top-level): Don't handle `byte-code' forms specially. (byte-compile-inline-lapcode): New function, taken from byte-opt.el. (byte-compile-unfold-bcf): New function. (byte-compile-form): Use it to optimize inline byte-code-functions. (byte-compile-function-form, byte-compile-defun): Simplify. (byte-compile-defmacro): Don't bother calling byte-compile-byte-code-maker.
* Merge from trunkStefan Monnier2011-03-215-194/+269
|\
| * * emacs-lisp/ert.el (ert-run-tests-batch): Remove unused variable.Christian Ohler2011-03-201-5/+4
| | | | | | | | | | | | (ert-delete-all-tests): Use `called-interactively-p' rather than `interactive-p'. (ert--make-xrefs-region): Respect END.
| * Fix tar package handling, and clean up package-subdirectory-regexp usage.Chong Yidong2011-03-191-26/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/startup.el (package-subdirectory-regexp): Move from package.el. Omit \\` and \\', and let callers add them. * lisp/emacs-lisp/package.el (package-strip-version) (package-load-all-descriptors): Add \\` and \\' to package-subdirectory-regexp before using it. (package-untar-buffer): New arg DIR; ensure that file untars only into this expected directory. Remove superfluous delete-region. (package-unpack): Caller changed. (package-tar-file-info): Use package-subdirectory-regexp.
| * * lisp/emacs-lisp/bytecomp.el (byte-compile-save-excursion): Change theStefan Monnier2011-03-141-1/+2
| | | | | | | | warning message.
| * * lisp/emacs-lisp/bytecomp.el (byte-compile-make-obsolete-variable):Stefan Monnier2011-03-111-0/+11
| | | | | | | | Disable obsolescence warnings in the file that declares it.
| * Fix package.el handling of version numbers like 1.0pre6.Chong Yidong2011-03-101-5/+32
| | | | | | | | | | | | | | * lisp/emacs-lisp/package.el (package-version-join): Impose a standard string representation for pre/alpha/beta version lists. (package-unpack-single): Standardize the directory name by passing it through package-version-join.
| * Fix package-strip-rcs-id to be more robust.Chong Yidong2011-03-101-7/+9
| | | | | | | | | | | | | | See http://lists.gnu.org/archive/html/emacs-devel/2011-03/msg00396.html * lisp/emacs-lisp/package.el (package-strip-rcs-id): Accept any version string that does not signal an error in version-to-list.
| * Use condition-case-no-debug in package.el.Chong Yidong2011-03-081-2/+2
| | | | | | | | | | * lisp/emacs-lisp/package.el (package-refresh-contents) (package-menu-execute): Use condition-case-no-debug.
| * * simple.el (shell-command-to-string): Use `process-file'.Michael Albinus2011-03-082-41/+44
| | | | | | | | | | | | | | | | * emacs-lisp/package.el (package-tar-file-info): Handle also remote files. * emacs-lisp/package-x.el (package-upload-buffer-internal): Use `equal' for upload base check.
| * Usability improvements to commands in package-x.el.Chong Yidong2011-03-061-108/+145
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/package-x.el (package-archive-upload-base): Make it a defcustom. (package--update-file): Doc fix. Accept relative file names. (package--archive-contents-from-file): Remove the argument, since it's necessarily always "archive-contents". (package-maint-add-news-item): Pass relative file name args to package--update-file. (package-upload-buffer-internal): Prompt for a destination if package-archive-upload-base is invalid. Create the directory if it does not exist. (package-upload-buffer, package-upload-file): Doc fix.
* | * emacs-lisp/cl-macs.el (cl-block-wrapper): Fix typo that broke CLChristian Ohler2011-03-201-1/+1
| | | | | | | | blocks.
* | * lisp/emacs-lisp/debug.el (debugger-setup-buffer): Revert local change toStefan Monnier2011-03-191-4/+2
| | | | | | | | print depth and length.
* | * lisp/emacs-lisp/cl-macs.el (cl-byte-compile-block, cl-block-wrapper)Stefan Monnier2011-03-181-30/+24
| | | | | | | | | | | | | | (cl-block-throw, cl-byte-compile-throw): Use a compiler-macro rather than a `byte-compile' hook to optimize away unused CL blocks, so that also works for lexbind code. Move the code after define-compiler-macro.
* | Remove bytecomp- prefix, plus misc changes.Stefan Monnier2011-03-167-379/+416
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/byte-opt.el (byte-compile-inline-expand): Make it work to inline lexbind interpreted functions into lexbind code. (bytedecomp-bytes): Not a dynamic var any more. (disassemble-offset): Get the bytes via an argument instead. (byte-decompile-bytecode-1): Use push. * lisp/emacs-lisp/bytecomp.el: Remove the bytecomp- prefix now that we use lexical-binding. (byte-compile-outbuffer): Rename from bytecomp-outbuffer. * lisp/emacs-lisp/cl-macs.el (load-time-value): * lisp/emacs-lisp/cl.el (cl-compiling-file): Adjust to new name. * lisp/emacs-lisp/pcase.el (pcase-mutually-exclusive-predicates): Add byte-code-function-p. (pcase--u1): Remove left-over code from early development. Fix case of variable shadowing in guards and predicates. (pcase--u1): Add a new `let' pattern. * src/image.c (parse_image_spec): Use Ffunctionp. * src/lisp.h: Declare Ffunctionp.
* | * src/eval.c (Ffunction): Use simpler format for closures.Stefan Monnier2011-03-132-3/+2
| | | | | | | | | | | | | | | | | | | | (Fcommandp, funcall_lambda): * src/doc.c (Fdocumentation, store_function_docstring): * src/data.c (Finteractive_form): * lisp/help-fns.el (help-function-arglist): * lisp/emacs-lisp/bytecomp.el (byte-compile-arglist-warn): * lisp/subr.el (apply-partially): Adjust to new closure format. * lisp/emacs-lisp/disass.el (disassemble-internal): Catch closures.
* | Try and fix w32 build; misc cleanup.Stefan Monnier2011-03-114-161/+177
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/subr.el (apply-partially): Move from subr.el; don't use lexical-let. (eval-after-load): Obey lexical-binding. * lisp/simple.el (apply-partially): Move to subr.el. * lisp/makefile.w32-in: Match changes in Makefile.in. (BIG_STACK_DEPTH, BIG_STACK_OPTS, BYTE_COMPILE_FLAGS): New vars. (.el.elc, compile-CMD, compile-SH, compile-always-CMD) (compile-always-SH, compile-calc-CMD, compile-calc-SH): Use them. (COMPILE_FIRST): Add pcase, macroexp, and cconv. * lisp/emacs-lisp/macroexp.el (macroexpand-all-1): Silence warning about calling CL's `compiler-macroexpand'. * lisp/emacs-lisp/bytecomp.el (byte-compile-preprocess): New function. (byte-compile-initial-macro-environment) (byte-compile-toplevel-file-form, byte-compile, byte-compile-sexp): Use it. (byte-compile-eval, byte-compile-eval-before-compile): Obey lexical-binding. (byte-compile--for-effect): Rename from `for-effect'. (display-call-tree): Use case. * lisp/emacs-lisp/byte-opt.el (for-effect): Don't declare as dynamic. (byte-optimize-form-code-walker, byte-optimize-form): Revert to old arg name. * lisp/Makefile.in (BYTE_COMPILE_FLAGS): New var. (compile-onefile, .el.elc, compile-calc, recompile): Use it.
* | Misc fixes, and use lexical-binding in more files.Stefan Monnier2011-03-1110-51/+74
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/subr.el (letrec): New macro. (with-wrapper-hook): Move from lisp/simple.el and don't use CL. * simple.el (with-wrapper-hook): Move with-wrapper-hook to subr.el. * lisp/help-fns.el (help-function-arglist): Handle subroutines as well. (describe-variable): Use special-variable-p to filter completions. * lisp/emacs-lisp/macroexp.el (macroexpand-all-1): Don't expand `declare' in defmacros. * lisp/emacs-lisp/cconv.el (cconv-convert, cconv-analyse-form): Handle `declare'. * lisp/emacs-lisp/cl.el (pushnew): Silence unfixable warning. * lisp/emacs-lisp/cl-macs.el (defstruct, define-compiler-macro): Mark unused arg as unused. * lisp/emacs-lisp/byte-opt.el (byte-optimize-lapcode): Use memq. * lisp/emacs-lisp/autoload.el (make-autoload): Don't assume the macro's first sexp is a list. (autoload-generate-file-autoloads): Improve error message. * lisp/emacs-lisp/advice.el (ad-arglist): Use help-function-arglist to understand the new byte-code arg format. * lisp/vc/smerge-mode.el: * lisp/vc/log-view.el: * lisp/vc/log-edit.el: * lisp/vc/cvs-status.el: * lisp/uniquify.el: * lisp/textmodes/css-mode.el: * lisp/textmodes/bibtex-style.el: * lisp/reveal.el: * lisp/newcomment.el: * lisp/emacs-lisp/smie.el: * lisp/abbrev.el: Use lexical-binding. * src/eval.c (Fprog1, Fprog2): Simplify and use XCDR/XCAR. (Fdefvar): Remove redundant SYMBOLP check. (Ffunctionp): Don't signal an error for undefined aliases. * doc/lispref/variables.texi (Converting to Lexical Binding): New node.
* | * lisp/emacs-lisp/bytecomp.el: Use lexical-binding.Stefan Monnier2011-03-101-77/+80
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (byte-recompile-directory): Remove unused var `bytecomp-dest'. (byte-recompile-file): Use derived-mode-p. (byte-compile-from-buffer): Remove arg `bytecomp-filename'. Use byte-compile-current-file instead. (byte-compile-file): Adjust call accordingly. (bytecomp-outbuffer): Move declaration before first use. (for-effect): Declare dynamic. (byte-compile-file-form-defmumble): Use byte-compile-current-file. (byte-compile-top-level, byte-compile-out-toplevel, byte-compile-form): Move dyn-binding of for-effect from function argument to let binding. (byte-compile-out-toplevel): Don't both passing for-effect to byte-optimize-lapcode. (byte-compile-top-level-body, byte-compile-body): Rename for-effect -> for-effect-arg so it's lexical. * lisp/subr.el (functionp): Remove, now that it's in src/eval.c.
* | * lisp/emacs-lisp/byte-opt.el: Use lexical binding.Stefan Monnier2011-03-101-10/+15
| | | | | | | | | | | | | | | | (for-effectm byte-compile-tag-number): Declare dynamic. (byte-optimize-form-code-walker, byte-optimize-form): Move dynamic binding of for-effect from function argument to let binding. (byte-decompile-bytecode-1): Move dynamic binding of bytedecomp-bytes from function argument to let binding.
* | Rewrite the cconv conversion algorithm, for clarity.Stefan Monnier2011-03-092-402/+247
| | | | | | | | | | | | | | | | | | | | | | | | | | * 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.
* | Merge from trunkStefan Monnier2011-03-0611-151/+304
|\|
| * Allow specifying local ELPA mirrors in package-archives.Chong Yidong2011-03-051-57/+67
| | | | | | | | | | | | | | | | | | | | * emacs-lisp/package.el (package-archives): Accept either ordinary directory names, in addition to HTTP URLs. (package--with-work-buffer): New macro. Handle normal directories. (package-handle-response): Don't display the failing buffer. (package-download-single, package-download-tar) (package--download-one-archive): Use package--with-work-buffer. (package-archive-base): Rename from package-archive-url.
| * * lisp/emacs-lisp/elp.el (elp-results): Fix off-by-one in header. (Bug#2746)Nikolaj Schumacher2011-03-051-1/+1
| |
| * Minor ewoc fix for bug#3261.Bob Rogers2011-03-031-0/+2
| | | | | | | | | | * lisp/emacs-lisp/ewoc.el (ewoc-goto-next): Give a more explicit error if there is no node.
| * Added fast path to ERT explanation of `equal'.Christian Ohler2011-03-031-16/+26
| | | | | | | | | | | | | | | | | | | | | | * 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.
| * Fix ERT bug related to quit handling.Christian Ohler2011-03-031-6/+14
| | | | | | | | | | | | | | * emacs-lisp/ert.el (ert--stats-set-test-and-result) (ert-char-for-test-result, ert-string-for-test-result) (ert-run-tests-batch, ert--print-test-for-ewoc): Handle `ert-test-quit'.
| * lisp/emacs-lisp/cl-macs.el (lexical-let*): Fix argument name in docstring.Juanma Barranquero2011-03-012-3/+3
| |
| * lisp/emacs-lisp/pcase.el (pcase, pcase--u1, pcase--q1): Fix typos in docstrings.Juanma Barranquero2011-02-281-5/+5
| |
| * * lisp/emacs-lisp/pcase.el (pcase--if): Try to invert test to reduce depth.Stefan Monnier2011-02-261-14/+87
| | | | | | | | | | | | | | | | | | (pcase-mutually-exclusive-predicates): New var. (pcase--split-consp, pcase--split-pred): Use it. (pcase--split-equal, pcase--split-member): When splitting against a pure predicate, run it to know the outcome. (pcase--u1): Mark vars that are actually used. (pcase--q1): Avoid introducing unused vars.
| * * lisp/emacs-lisp/assoc.el: Remove misleading `sort'.Stefan Monnier2011-02-261-5/+5
| | | | | | | | | | | | | | (aput, adelete, amake): Replace `eval' -> `symbol-value'. Suggested by Michael Heerdegen <michael_heerdegen@web.de>. Fixes: debbugs:8126
| * Fix package uploading for newly made or local archives.Jambunathan K2011-02-251-22/+67
| | | | | | | | | | | | | | | | | | | | * emacs-lisp/package-x.el (package--archive-contents-from-url) (package--archive-contents-from-file): New functions. (package-update-news-on-upload): New var. (package-upload-buffer-internal): Extract archive-contents from package-archive-upload-base if it is not found at archive-url. Obey package-update-news-on-upload. (package-upload-buffer, package-upload-file): Doc fix.
| * Avoid some possible prompts from autoloads.el.Glenn Morris2011-02-231-6/+10
| | | | | | | | | | | | * lisp/emacs-lisp/autoload.el (autoload-save-buffers) (autoload-find-destination, update-directory-autoloads): Avoid prompts when updating autoloads.
| * * lisp/emacs-lisp/bytecomp.el (byte-compile-disable-print-circle): Obsolete.Stefan Monnier2011-02-231-0/+1
| |
* | Fix pcase memoizing; change lexbound byte-code marker.Stefan Monnier2011-03-055-44/+89
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * src/bytecode.c (exec_byte_code): Remove old lexical binding slot handling and replace it with the a integer args-desc handling. * eval.c (funcall_lambda): Adjust arglist test accordingly. * lisp/emacs-lisp/bytecomp.el (byte-compile-arglist-signature): Handle integer arglist descriptor. (byte-compile-make-args-desc): Make integer arglist descriptor. (byte-compile-lambda): Use integer arglist descriptor to mark lexical byte-coded functions instead of an extra slot. * lisp/help-fns.el (help-add-fundoc-usage): Don't add a dummy doc. (help-split-fundoc): Return a nil doc if there was no actual doc. (help-function-arglist): Generate an arglist from an integer arg-desc. * lisp/emacs-lisp/pcase.el (pcase--memoize): Rename from pcase-memoize; Make only the key weak. (pcase): Change the key used in the memoization table, so it does not always get GC'd away. * lisp/emacs-lisp/macroexp.el (macroexpand-all-1): Slight change to the pcase pattern to generate slightly better code.
* | * doc/lispref/variables.texi (Scope): Mention the availability of lexbind.Stefan Monnier2011-03-014-44/+120
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (Lexical Binding): New node. * doc/lispref/eval.texi (Eval): Add `eval's new `lexical' arg. * lisp/emacs-lisp/cconv.el (cconv-liftwhen): Increase threshold. (cconv-closure-convert-rec): Convert interactive spec in empty lexenv. (cconv-analyse-use): Improve unused vars warnings. (cconv-analyse-form): Analyze interactive spec in empty lexenv. * lisp/emacs-lisp/bytecomp.el (byte-compile-lambda): Always byte-compile the interactive spec in lexical-binding mode. (byte-compile-refresh-preloaded): Don't reload byte-compiler files. * lisp/custom.el (custom-initialize-default): Use defvar. (custom-declare-variable): Set the special-variable-p flag. * lisp/help-fns.el (help-make-usage): Drop leading underscores. * lisp/dired.el (dired-revert, dired-make-relative): Mark unused args. (dired-unmark-all-files): Remove unused var `query'. (dired-overwrite-confirmed): Declare. (dired-restore-desktop-buffer): Don't use dynamically scoped arg names. * lisp/mpc.el: Mark unused args. (mpc--faster-toggle): Remove unused var `songnb'. * lisp/server.el (server-kill-buffer-running): Move before first use. * lisp/minibuffer.el: Mark unused args. * src/callint.c (quotify_arg): Simplify the logic. (Fcall_interactively): Use lexical binding when evaluating the interactive spec of a lexically bound function.
* | * lisp/emacs-lisp/cconv.el (cconv-closure-convert-rec): Fix last change forStefan Monnier2011-02-261-4/+9
| | | | | | | | λ-lift candidates that end up not λ-lifted.
* | Compute freevars in cconv-analyse.Stefan Monnier2011-02-265-345/+268
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/cconv.el: Compute freevars in cconv-analyse. (cconv-mutated, cconv-captured): Remove. (cconv-captured+mutated, cconv-lambda-candidates): Don't give them a global value. (cconv-freevars-alist): New var. (cconv-freevars): Remove. (cconv--lookup-let): Remove. (cconv-closure-convert-function): Extract from cconv-closure-convert-rec. (cconv-closure-convert-rec): Adjust to above changes. (fboundp): New function. (cconv-analyse-function, form): Rewrite. * lisp/emacs-lisp/bytecomp.el (byte-compile-initial-macro-environment): Handle declare-function here. (byte-compile-obsolete): Remove. (byte-compile-arglist-warn): Check late defsubst here. (byte-compile-file-form): Simplify. (byte-compile-file-form-defsubst): Remove. (byte-compile-macroexpand-declare-function): Rename from byte-compile-declare-function, turn it into a macro-expander. (byte-compile-normal-call): Check obsolescence. (byte-compile-quote-form): Remove. (byte-compile-defmacro): Revert to trunk's definition which seems to work just as well and handles `declare'. * lisp/emacs-lisp/byte-run.el (make-obsolete): Don't modify byte-compile. * lisp/Makefile.in (BIG_STACK_DEPTH): Increase to 1200. (compile-onefile): Pass $(BIG_STACK_OPTS) before "-l bytecomp". * lisp/emacs-lisp/macroexp.el: Use lexbind. (macroexpand-all-1): Check macro obsolescence. * lisp/vc/diff-mode.el: Use lexbind. * lisp/follow.el (follow-calc-win-end): Simplify.
* | Get rid of funvec.Stefan Monnier2011-02-249-285/+169
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/bytecomp.el (byte-compile-lapcode): Handle new form of `byte-constant'. (byte-compile-close-variables, displaying-byte-compile-warnings): Add edebug spec. (byte-compile-toplevel-file-form): New fun, split out of byte-compile-file-form. (byte-compile-from-buffer): Use it to avoid applying cconv multiple times. (byte-compile): Only strip `function' if it's present. (byte-compile-lambda): Add `reserved-csts' argument. Use new lexenv arg of byte-compile-top-level. (byte-compile-reserved-constants): New var. (byte-compile-constants-vector): Obey it. (byte-compile-constants-vector): Handle new `byte-constant' form. (byte-compile-top-level): Add args `lexenv' and `reserved-csts'. (byte-compile-form): Don't check callargs here. (byte-compile-normal-call): Do it here instead. (byte-compile-push-unknown-constant) (byte-compile-resolve-unknown-constant): Remove, unused. (byte-compile-make-closure): Use `make-byte-code' rather than `curry', putting the environment into the "constant" pool. (byte-compile-get-closed-var): Use special byte-constant. * lisp/emacs-lisp/byte-opt.el (byte-optimize-form-code-walker): Handle new intermediate special form `internal-make-vector'. (byte-optimize-lapcode): Handle new form of `byte-constant'. * lisp/help-fns.el (describe-function-1): Don't handle funvecs. * lisp/emacs-lisp/macroexp.el (macroexpand-all-1): Only convert quote to function if the content is a lambda expression, not if it's a closure. * emacs-lisp/eieio-come.el: Remove. * lisp/emacs-lisp/eieio.el: Don't require eieio-comp. (defmethod): Do a bit more work to find the body and wrap it into a function before passing it to eieio-defmethod. (eieio-defmethod): New arg `code' for it. * lisp/emacs-lisp/debug.el (debugger-setup-buffer): Don't hide things in debugger backtrace. * lisp/emacs-lisp/cl-extra.el (cl-macroexpand-all): Use backquotes, and be more careful when quoting a function value. * lisp/emacs-lisp/cconv.el (cconv-freevars): Accept defvar/defconst. (cconv-closure-convert-rec): Catch stray `internal-make-closure'. * lisp/Makefile.in (COMPILE_FIRST): Compile pcase and cconv early. * src/eval.c (Qcurry): Remove. (funcall_funvec): Remove. (funcall_lambda): Move new byte-code handling to reduce impact. Treat all args as lexical in the case of lexbind. (Fcurry): Remove. * src/data.c (Qfunction_vector): Remove. (Ffunvecp): Remove. * src/lread.c (read1): Revert to calling make_byte_code here. (read_vector): Don't call make_byte_code any more. * src/lisp.h (enum pvec_type): Rename back to PVEC_COMPILED. (XSETCOMPILED): Rename back from XSETFUNVEC. (FUNVEC_SIZE): Remove. (FUNVEC_COMPILED_TAG_P, FUNVEC_COMPILED_P): Remove. (COMPILEDP): Rename back from FUNVECP. * src/fns.c (Felt): Remove unexplained FUNVEC check. * src/doc.c (Fdocumentation): Don't handle funvec. * src/alloc.c (make_funvec, Ffunvec): Remove. * doc/lispref/vol2.texi (Top): * doc/lispref/vol1.texi (Top): * doc/lispref/objects.texi (Programming Types, Funvec Type, Type Predicates): * doc/lispref/functions.texi (Functions, What Is a Function, FunctionCurrying): * doc/lispref/elisp.texi (Top): Remove mentions of funvec and curry.
* | * lisp/emacs-lisp/cconv.el (cconv-closure-convert-rec): Let the byteStefan Monnier2011-02-212-39/+36
| | | | | | | | | | | | | | | | | | | | compiler choose the representation of closures. (cconv--env-var): Remove. * lisp/emacs-lisp/bytecomp.el (byte-compile--env-var): New var. (byte-compile-make-closure, byte-compile-get-closed-var): New functions. * lisp/cedet/semantic/wisent/comp.el (wisent-byte-compile-grammar): Macroexpand before passing to byte-compile-form.
* | Merge from trunkStefan Monnier2011-02-2111-52/+124
|\|
| * Import filemode module from gnulib.Paul Eggert2011-02-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * .bzrignore: Add lib/sys/. * Makefile.in (GNULIB_MODULES): Add filemode. * lib/Makefile.am (MOSTLYCLEANDIRS): New macro. * lib/filemode.c: Renamed from src/filemode.c and regenerated from gnulib. This adds support for some more file types, e.g., Cray DMF migrated files. * lisp/emacs-lisp/find-gc.el (find-gc-source-files): Remove filemode.c. * lib/filemode.h, lib/sys_stat.in.h, m4/filemode.m4, m4/st_dm_mode.m4: * m4/sys_stat_h.m4: New files, generated from gnulib. * aclocal.m4, configure, lib/Makefile.in, lib/gnulib.mk, m4/gl-comp.m4: Regenerate. 2011-02-20 Paul Eggert <eggert@cs.ucla.edu>
| * Fix incorrect changes introduced in 2011-02-02T17:59:44Z!sds@gnu.org.Chong Yidong2011-02-181-2/+2
| | | | | | | | | | | | | | | | | | | | | | * lisp/apropos.el (apropos-print): Call apropos-mode before setting up buffer variables. Use inhibit-read-only. * lisp/emacs-lisp/package.el (package--list-packages): Call package-menu-mode before setting up buffer variables. * lisp/play/solitaire.el (solitaire): Call solitaire-mode before setting up buffer variables. Use inhibit-read-only.
| * Use generated-autoload-file for internal eieio autoloads.Glenn Morris2011-02-183-9/+75
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/eieio-custom.el: Set generated-autoload-file. (customize-object): Add autoload cookie. * lisp/emacs-lisp/eieio-opt.el: Set generated-autoload-file. (eieio-browse, describe-class, eieio-describe-class) (eieio-describe-constructor, describe-generic, eieio-describe-generic) (eieio-help-mode-augmentation-maybee): Add autoload cookies. * lisp/emacs-lisp/eieio.el: Regenerate with automatic autoloads. * lisp/Makefile.in (autoloads): Make eieio.el writable.
| * * lisp/emacs-lisp/pcase.el (pcase--u1): Understand non-linear patterns.Stefan Monnier2011-02-171-1/+8
| |
| * Fix ERT.Christian Ohler2011-02-181-11/+11
| | | | | | | | | | | | | | | | | | | | * lisp/emacs-lisp/ert.el (ert--setup-results-buffer) (ert-results-pop-to-backtrace-for-test-at-point) (ert-results-pop-to-messages-for-test-at-point) (ert-results-pop-to-should-forms-for-test-at-point) (ert-results-pop-to-timings): Revert parts of 2011-02-02T17:59:44Z!sds@gnu.org that were incorrect and unnecessary. This should make `make check' pass again.
| * Merge changes from emacs-23 branchChong Yidong2011-02-123-18/+18
| |\
| | * Merge changes from emacs-23 branchChong Yidong2011-02-123-17/+17
| |/|