summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Enhance struct Lisp_Subr to hold the alternative "BC_" function.scratch/accurate-warning-posAlan Mackenzie2019-04-054-13/+70
| | | | | | | | | | | | | | | | | | | | | | | Also fix a GC bug, where symbols with position were not being disabled. * src/lisp.h (union Lisp_Function): New type. (struct Lisp_Subr): Add fields normal_function, BC_function, and next. (DEFUN): Setup all three function fields to the subr (BC_function is still a dummy), set field next to NULL. * src/alloc.c (Fgarbage_collect): Move the binding of Qsymbols_with_pos_enabled to garbage_collect_1 so that it gets bound when GC is invoked via garbage_collect. * src/lread.c (subr_ptr, using_BC_subrs): New static variables. (Fswitch_to_BC_subrs, Fswitch_to_normal_subrs): New defuns. (defsubr): Chain new subr to previous using field next and variable subr_ptr. (init_lread): Initialise subr_ptr to NULL. (syms_of_lread): Create subrs Sswitch_to_BC_subrs and Sswitch_to_normal_subrs. * src/pdumper.c (dump_subr): Enhance to dump struct Lisp_Subr's new fields. Update the expected value of HASH_Lisp_Subr_xxxxxxxxxx. (dump_vectorlike): Also dump PVEC_SYMBOL_WITH_POSes.
* Merge branch 'master' into scratch/accurate-warning-posAlan Mackenzie2019-03-302769-26924/+50169
|\
| * Allow a CC Mode derived mode to have strings delimited by single quotes.Alan Mackenzie2019-03-302-21/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also fix the bug where the delimiters of '\033', etc. got the error face. * lisp/progmodes/cc-langs.el (c-single-quotes-quote-strings): Enhance the docr string. (c-string-delims): Change doc string to doc comment. * listp/progmodes/cc-mode.el (c-before-change-check-unbalanced-strings): In searches and comparisons, take account of the string delimiters possibly being '. Fix argument in call of c-before-change-check-unbalanced-strings. (c-parse-quotes-before-change, c-parse-quotes-after-change): Bind case-fold-search to nil. Analyze escape constructs inside character constants more accurately, in particular accepting as valid more than one character after /[0-7], /x, /u, and /U. Amend calculations to account for this extra length.
| * Fix a thinko in a recent commitEli Zaretskii2019-03-301-4/+6
| | | | | | | | | | * src/buffer.c (Fkill_buffer): Fix last change. (Bug#31138) Reported by Mattias Engdegård <mattiase@acm.org>.
| * Release regexp before signalling overflow errorMattias Engdegård2019-03-301-1/+6
| | | | | | | | | | | | * src/search.c (looking_at_1, search_buffer_re): Unfreeze the regexp buffer before signalling a matcher overflow, since the error processing may require quite some regexp use as well (Bug#34910).
| * Fix spurious regexp reentrancy errorMattias Engdegård2019-03-301-6/+9
| | | | | | | | | | | | | | * src/search.c (compile_pattern): Don't give up if the last regexp cache entry is busy. Instead, use the last (least recently used) non-busy entry, and only signal a reentrancy error if there is no free entry at all (Bug#34910).
| * Don't run buffer-related hooks in " *code conversion work*" buffersEli Zaretskii2019-03-305-31/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Note: portions of this change were mistakenly pushed as part of an unrelated commit a35a1f6a9. * src/buffer.c (Fget_buffer_create): Set inhibit_buffer_hooks non-zero for temporary buffers created by coding.c. Don't run buffer-list-update-hook for such buffers. (Frename_buffer, Fkill_buffer, record_buffer) (Fbury_buffer_internal): Don't run hooks for buffers whose inhibit_buffer_hooks flag is set. * src/buffer.h (struct buffer): New member inhibit_buffer_hooks. * src/pdumper.c (dump_buffer): Dump the new field. Update the hash value in HASH_buffer_XXX. * src/coding.c (make_conversion_work_buffer): Function deleted; code moved to code_conversion_save. (code_conversion_save): Insert code from make_conversion_work_buffer, but arrange for unwind-protecting the current buffer before switching to the work buffer. This avoids leaving reused_workbuf_in_use set if user presses C-g during encoding/decoding. (Vcode_conversion_workbuf_name): Now external variable. * src/coding.h (Vcode_conversion_reused_workbuf): Declare.
| * Extend comment about scope of tramp-test05-expand-file-name-relativeMichael Albinus2019-03-291-3/+3
| |
| * Gnus: Automatically render text/calendar in a human-friendly wayStefan Monnier2019-03-292-49/+47
| | | | | | | | | | | | | | | | | | | | * lisp/gnus/mm-decode.el (mm-inline-media-tests): Add text/calendar entry. Use (fboundp 'device-sound-enabled-p) rather than fishing for features. (mm-automatic-display): Add text/calendar entry. * lisp/gnus/gnus-icalendar.el: Use lexical-binding. Remove redundant :group args. (gnus-icalendar-mm-inline): Add autoload cookie.
| * Fix (again) regexp bug in CC Mode.Alan Mackenzie2019-03-291-1/+1
| | | | | | | | | | * lisp/progmodes/cc-mode.el (c-after-change-mark-abnormal-strings): "|\\\r" -> "\\|\r".
| * Use memql instead of memq in pcaseMattias Engdegård2019-03-282-5/+7
| | | | | | | | | | | | * lisp/emacs-lisp/pcase.el (pcase--u1): Use memql instead of memq to work with bignums (Bug#34781). * test/lisp/emacs-lisp/pcase-tests.el (pcase-tests-member): Test the above.
| * Initiate gnus-active-hashtb before making ephemeral groupEric Abrahamsen2019-03-281-1/+2
| | | | | | | | | | * lisp/gnus/gnus-group.el (gnus-group-read-ephemeral-group): Needs to be a hash table, not nil.
| * Fix display of sliced images on MS-WindowsEli Zaretskii2019-03-281-10/+28
| | | | | | | | | | | | * src/w32term.c (x_draw_image_foreground): Fix detection of scaled images for sliced images. Scale the original width of a slice and its coordinates of origin as well.
| * * lisp/net/tramp.el (tramp-accept-process-output): Use `push'.Michael Albinus2019-03-281-1/+1
| |
| * Simpler way to export HAVE_X_WINDOWS to GDBPaul Eggert2019-03-272-18/+13
| | | | | | | | | | | | | | | | | | | | * src/.gdbinit: Simplify by removing dependency on globals implementation. This is useful for a future performance improvement that I have in mind. * src/alloc.c (enum defined_HAVE_X_WINDOWS, defined_HAVE_X_WINDOWS): New enum and constant. (gdb_make_enums_visible) [__GNUC__]: Use it, to make defined_HAVE_X_WINDOWS visible to GDB.
| * Tweak re_registers allocationPaul Eggert2019-03-272-18/+10
| | | | | | | | | | | | | | * src/regex-emacs.c (re_match_2_internal): No need to allocate one extra trailing search register; Emacs does not use it. Avoid quadratic behavior on reallocation.
| * No need for m_search_regs_saved in thread.hPaul Eggert2019-03-272-16/+5
| | | | | | | | | | | | | | * src/search.c (save_search_regs, restore_search_regs): Don’t use m_search_regs_saved; it’s equivalent to saved_search_regs.num_regs != 0. * src/thread.h (struct thread_state): Remove m_search_regs_saved.
| * Fix search_regs memory leak when thread destroyedPaul Eggert2019-03-271-0/+12
| | | | | | | | | | * src/thread.c (free_search_regs): New function. (finalize_one_thread): Use it.
| * * lisp/frame.el (make-frame-on-monitor): Add default value. (Bug#34516)Juri Linkov2019-03-271-6/+10
| |
| * * lisp/net/tramp.el (tramp-accept-process-output): Let progress reporter run.Michael Albinus2019-03-271-0/+5
| |
| * * test/lisp/mail/rmail-tests.el (rmail-autoload): Fix its doc.Charles A. Roelli2019-03-271-1/+1
| |
| * Tune css-mode regexpPaul Eggert2019-03-271-1/+1
| | | | | | | | | | | | * lisp/textmodes/css-mode.el (css--font-lock-keywords): Omit unnecessary \(?: \) in regexp. Suggested by Mattias Engdegård in: https://lists.gnu.org/r/emacs-devel/2019-03/msg01042.html
| * Improve documentation of 'alist-get' (Bug#34708)Michael Heerdegen2019-03-271-2/+24
| | | | | | | | | | * lisp/subr.el (alist-get): Enhance part of docstring explaining usage in place expressions.
| * Use regexp-opt-charset to improve regexp tweaksPaul Eggert2019-03-273-10/+12
| | | | | | | | | | | | | | | | * lisp/emacs-lisp/regexp-opt.el (regexp-opt): Reword confusing sentence in doc string. * lisp/erc/erc.el (erc-lurker-maybe-trim): * lisp/mail/footnote.el (footnote-hebrew-numeric-regex): Improve by using regexp-opt-charset.
| * Attempt to fix crashes under GDB on Windows 10Eli Zaretskii2019-03-272-39/+51
| | | | | | | | | | | | | | * src/pdumper.c (dump_discard_mem) [VM_SUPPORTED == VM_MS_WINDOWS]: Don't pass NULL pointer as last argument to VirtualProtect. Reported by Martin Rudalics <rudalics@gmx.at>.
| * Minor xml.el tweaksPaul Eggert2019-03-271-2/+2
| | | | | | | | | | | | | | | | * lisp/xml.el (xml-name-start-char-re, xml-name-char-re): No need to call concat. (xml-name-char-re): Use \u escapes rather than chars inline, so that the code matches the comments better and is easier to audit.
| * Use connection-local setting for tramp-remote-pathMichael Albinus2019-03-272-81/+117
| | | | | | | | | | | | | | | | * doc/misc/tramp.texi (Remote programs): Mention connection-local settings for `tramp-remote-path'. * lisp/net/tramp-sh.el (tramp-get-remote-path): Expand connection-local variables.
| * Avoid recently obsolete seq-contains in css-modeBasil L. Contovounesios2019-03-271-1/+1
| | | | | | | | | | * lisp/textmodes/css-mode.el (css--join-nested-selectors): Replace recently obsolete seq-contains with new predicate seq-contains-p.
| * * lisp/xml.el (xml-name-char-re): Remove superfluous `-' in regexp.Mattias Engdegård2019-03-271-1/+1
| |
| * Improve C++ raw string fontification.Alan Mackenzie2019-03-275-238/+562
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Integrate the handling of raw string and ordinary string fontification. * lisp/progmodes/cc-defs.el (c-font-lock-flush) (c-search-forward-char-property-without-value-on-char): new macros. (c-point): In the 'eoll arm, check for eobp. (c-search-forward-char-property-with-value-on-char): Handle the &optional limit argument being nil. (c-clear-char-property-with-value-on-char-function) (c-clear-char-property-with-value-on-char): Return the position of the first cleared property. * lisp/progmodes/cc-engine.el (c-find-decl-prefix-search): Don't spuriously recognize the change of face at a ) as the start of a string (a "pseudo match"). (c-old-beg-rs c-old-end-rs): New variables. (c-raw-string-pos): Analyze raw string delimiters more carefully. (c-raw-string-in-end-delim): New function. (c-depropertize-raw-string): Largely rewritten. (c-before-change-check-raw-strings): New functionality: only remove the syntax-table text properties from raw strings whose delimiters are about to change. (c-propertize-raw-string-id): New function. (c-after-change-re-mark-raw-strings): Remove, incorporating functionality into other functions. (c-propertize-raw-string-opener): Largely rewritten. (c-after-change-re-mark-raw-strings): Removed. (c-after-change-unmark-raw-strings, c-after-change-unmark-raw-strings): New functions. * lisp/progmodes/cc-fonts.el (c-font-lock-raw-strings): Largely rewritten. * lisp/progmodes/cc-langs.el (c-before-font-lock-functions): Replace c-after-change-re-mark-unbalanced-strings by c-after-change-mark-abnormal-strings in the t, c+objc, c++ and java sections. Add c-after-change-unmark-raw-strings and remove c-after-change-re-mark-raw-strings from the c++ section. * lisp/progmodes/cc-mode.el (c-old-BEG c-old-END): Remove. (c-old-END-literality): New variable. (c-depropertize-CPP): Remove syntax-table properties from raw strings within macros. (c-before-change-check-unbalanced-strings): Call c-truncate-semi-nonlit-pos-cache to preserve the integrity of the cache. (c-before-change-check-unbalanced-strings): Call c-truncate-semi-nonlit-pos-cache, largely rewritten. (c-after-change-re-mark-unbalanced-strings): Renamed to c-after-change-mark-abnormal-strings. Call c-maybe-re-mark-raw-string.
| * * lisp/calc/calc-forms.el (calc-hms-notation): Fix interactiveAndreas Schwab2019-03-271-1/+1
| | | | | | | | prompt.
| * * lisp/emacs-lisp/map.el (map-inplace): Fix the message of the error.Nicolas Petton2019-03-271-1/+1
| |
| * Support native image resizing on cairoYAMAMOTO Mitsuharu2019-03-274-15/+34
| | | | | | | | | | | | | | | | | | | | | | | | * src/xterm.c (x_cr_draw_image): Add arguments image_width and image_height and support scaling. All callers changed. * src/image.c (Fimage_scaling_p): Return t when USE_CAIRO. (x_set_image_size) [USE_CAIRO]: Record the scaled dimensions in the image struct. * src/dispextern.h (HAVE_NATIVE_SCALING): Define when USE_CAIRO as well. * etc/NEWS: Update the announcement of native image scaling.
| * Fix cairo image drawing with boxYAMAMOTO Mitsuharu2019-03-271-20/+35
| | | | | | | | | | | | | | | | * src/xterm.c (x_cr_draw_image): Don't call cr_clip for non-mask case. (x_draw_image_foreground) [USE_CAIRO]: Draw image here ... (x_draw_image_glyph_string) [USE_CAIRO]: ... instead of here. (x_draw_image_foreground, x_draw_image_foreground_1) (x_draw_image_glyph_string) [USE_CAIRO]: Ifdef away unused code path.
| * 2019-03-26 regex cleanupPaul Eggert2019-03-2610-27/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problems reported by Mattias Engdegård in: https://lists.gnu.org/r/emacs-devel/2019-03/msg01028.html * lisp/align.el (align-rules-list): * lisp/speedbar.el (speedbar-check-read-only, speedbar-check-vc): * lisp/vc/diff-mode.el (diff-add-change-log-entries-other-window): * lisp/woman.el (woman-parse-numeric-arg): Put "-" at end of character alternatives, since a range was not intended. * lisp/erc/erc.el (font-lock): * lisp/mail/footnote.el (cl-seq): Avoid duplicate character alternatives by using cl-seq API. * lisp/mail/footnote.el (footnote--current-regexp): * lisp/textmodes/css-mode.el (css--font-lock-keywords): Avoid repetition of repetition. * lisp/net/webjump.el (webjump-url-encode): Add ~ to character alternatives, and rewrite confusing range. * lisp/progmodes/verilog-mode.el (verilog-compiler-directives) (verilog-assignment-operator-re): Remove duplicate. * lisp/progmodes/verilog-mode.el (verilog-preprocessor-re): * lisp/textmodes/css-mode.el (css--font-lock-keywords): Don’t escape a char that doesn’t need it. * lisp/textmodes/picture.el (picture-tab-chars): In docstring, do not say regexp characters will be quoted; merely say in another way that the syntax is that of character alternatives. (picture-set-tab-stops, picture-tab-search): Don’t attempt to regexp-quote picture-tab-chars. (picture-tab-search): Quote \ in picture-tab-chars for skip-chars-backwards, which treats \ differently than regexp character alternatives do.
| * * easy-mmode.el: simplify via custom-current-groupStefan Monnier2019-03-261-6/+0
| | | | | | | | | | * lisp/emacs-lisp/easy-mmode.el (define-globalized-minor-mode): Don't try and guess a default :group, defcustom does it better anyway.
| * Use cairo image surface instead of pattern for fringe bitmapYAMAMOTO Mitsuharu2019-03-261-16/+8
| | | | | | | | | | | | * src/xterm.c (fringe_bmp, x_cr_define_fringe_bitmap) (x_cr_destroy_fringe_bitmap, x_cr_draw_image) [USE_CAIRO]: Change type of fringe bitmap.
| * Fix cairo scrolling for left scroll bars caseYAMAMOTO Mitsuharu2019-03-261-3/+2
| | | | | | | | | | * src/xterm.c (x_scroll_run) [USE_CAIRO]: Fix scrolling by unusing WINDOW_LEFT_EDGE_X. (Bug#31288)
| * Support tool bar icon image on GTK+ >= 3.10 with cairoYAMAMOTO Mitsuharu2019-03-261-2/+35
| | | | | | | | | | | | | | * src/gtkutil.c (xg_get_image_for_pixmap) [USE_CAIRO]: Use cairo image surface for GtkImage source. (xg_tool_item_stale_p, update_frame_tool_bar) [USE_CAIRO]: Use cairo image surface instead of pixmap for data associated with tool bar item.
| * Simplify cairo image surface creation and destructionYAMAMOTO Mitsuharu2019-03-262-52/+48
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * src/dispextern.h (struct image) [USE_CAIRO]: Remove member cr_data2. * src/image.c (set_cairo_image_surface): New function split from original create_cairo_image_surface. Call cairo_surface_mark_dirty. (create_cairo_image_surface): Just create image surface and return it. (x_clear_image): Don't free cr_data2. (xpm_load, pbm_load, png_load_body, jpeg_load_body, tiff_load) (gif_load, imagemagick_load_image, svg_load_image) [USE_CAIRO]: Use new create_cairo_image_surface and cairo_image_surface_get_data instead of xmalloc. Use set_cairo_image_surface instead of old create_cairo_image_surface. (pbm_load) [USE_CAIRO]: Call cairo_surface_destroy for surface instead of xfree for data. (gif_load) [USE_CAIRO]: Multiply y-coordinate value by width instead of subimg_width.
| * ; * etc/NEWS: Fix Tabulated List mode nesting.Basil L. Contovounesios2019-03-261-1/+1
| |
| * Port recent ngettext stub to non-glibcPaul Eggert2019-03-251-25/+9
| | | | | | | | | | | | | | * src/editfns.c: Don’t try to call glibc ngettext; we’re not ready for that yet. (Fngettext): Do not restrict integer arguments to fixnums. Improve doc string a bit.
| * Update from Gnulib.Paul Eggert2019-03-2514-268/+195
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This incorporates: 2019-03-23 Support cross-compilation to musl libc 2019-03-23 noreturn: In C++ mode with clang, use _Noreturn as fallback 2019-03-22 _Noreturn: beware of C's _Noreturn in C++ pre C++11 2019-03-19 Help making signal handlers more reliable 2019-03-18 _Noreturn: clang and MSVC do support [[noreturn]] in C++11 2019-03-17 _Noreturn: GCC 4.7 does not support [[noreturn]] in C++11 2019-03-14 all: Update URLs to msdn.microsoft.com * doc/misc/texinfo.tex, lib/_Noreturn.h, lib/gettimeofday.c: * lib/mktime.c, lib/regcomp.c, lib/regexec.c, lib/stat-time.h: * lib/utimens.c, m4/fdopendir.m4, m4/getgroups.m4: * m4/gettimeofday.m4, m4/gnulib-common.m4, m4/putenv.m4, m4/utimes.m4: Update from gnulib.
| * * lisp/vc/vc.el (vc-diff-mergebase, vc-log-mergebase): New commands.Juri Linkov2019-03-254-4/+75
| | | | | | | | | | | | | | | | * lisp/vc/vc-git.el (vc-git-mergebase): New function. (vc-git-print-log): Interpret string value of arg LIMIT as an end-revision. * lisp/vc/vc-hooks.el (vc-prefix-map): Bind 'vc-log-mergebase' to 'C-x v M L', and 'vc-diff-mergebase' to 'C-x v M D'. (Bug#33950)
| * Fix alignment bug with pure bignumsPaul Eggert2019-03-251-4/+9
| | | | | | | | | | | | | | | | Problem found on 32-bit sparc, which has stricter alignment checking than x86-64. * src/alloc.c (pure_alloc): When TYPE is negative it now specifies the negation of the required alignment of the result. (make_pure_bignum): Specify bignum limb alignment.
| * * lisp/international/mule-cmds.el (ngettext): Move to editfns.c.Juri Linkov2019-03-252-15/+38
| | | | | | | | | | * src/editfns.c (Fngettext): Move from mule-cmds.el and use gettext's ngettext when available.
| * Fix text property bug in gnus-group-list-activeEric Abrahamsen2019-03-251-1/+1
| | | | | | | | | | | | * lisp/gnus/gnus-group.el (gnus-group-list-active): The property value should be the group name, not the value of gethash. Ie, it should be the key, not the value.
| * Don't save Gnus' dummy.group to the .newsrc.eld fileEric Abrahamsen2019-03-251-1/+1
| | | | | | | | | | * lisp/gnus/gnus-start.el (gnus-gnus-to-quick-newsrc-format): Remove the "dummy.group" element.
| * Handle multiple possible types for Gnus group namesEric Abrahamsen2019-03-251-3/+6
| | | | | | | | | | * lisp/gnus/gnus-start.el (gnus-active-to-gnus-format): Numbers, symbols, and strings.
| * Fix a dns-mode reentrancy bugPaul Eggert2019-03-251-1/+1
| | | | | | | | | | * lisp/textmodes/dns-mode.el (dns-mode-ipv6-to-nibbles): Don’t assume kill-new does no matching.