Alan Mackenzie [Sat, 30 Apr 2016 16:37:41 +0000 (16:37 +0000)]
CC Mode: Recognize a noise macro with parens after a declarator's identifier
* lisp/progmodes/cc-engine (c-forward-decl-or-cast-1): In the while loop
following comment "Skip over type decl suffix operators." insert code also
to check for noise macros with parentheses.
Explictly explain that package-initialize loads the packages
* lisp/emacs-lisp/package.el (package-initialize): Be explicit
in saying that `package-initialize' obviates adjusting the
path or requiring the packages, as this is a question that
apparently comes up now and then (bug#18829).
Move doc of backup-directory-alist to the Backup node
* doc/emacs/files.texi (Backup): Move the documentation of
`backup-directory-alist' here from the "Single or Numbered
Backups" node, because it doesn't seem to have much to do with
numbering (bug#18692).
Remove uses of the unused to-end parameter from simple.el
* lisp/simple.el (line-move-partial): Remove usages of the
unused to-end parameter, and make it optional (bug#14844).
(line-move): Remove use of the unused to-end parameter.
* lisp/cus-edit.el (custom-buffer-create): _ chars are
automatically removed when displaying help, so fix the last
doc change.
(custom-buffer-create-other-window): Ditto.
* lisp/cus-edit.el (custom-buffer-create-other-window): Don't
pass the unused description value on (for clarity) (bug#10540).
(custom-buffer-create): Ditto
* lisp/ibuffer.el (ibuffer-mode-operate-map): Move the diff
command to the "Operate" menu, and remove the customisation
entry to make the "View" menu more logical (bug#1150).
* lisp/progmoes/python.el (python-font-lock-keywords): Clean up the exception
list, adding a number of new Python 3 exceptions and moving some exceptions
to the Python 2 and 3 list as Python 2.7 includes them.
Anders Lindgren [Tue, 26 Apr 2016 18:58:52 +0000 (20:58 +0200)]
Fix bug#22891: wrong terminal width when a fringe width is zero.
When either fringe width is zero, Emacs reserved one column for a
continuation glyph. Terminal windows does not take this into
account when the frame is resized.
* lisp/window.el (window-adjust-process-window-size): Use
`window-max-chars-per-line' instead of `window-body-width'.
* lisp/term.el (term-window-width): Remove function. (It does the
same as `window-max-chars-per-line' but without recent bug fixes.)
(term-mode): Use `window-max-chars-per-line' instead of
`term-window-width'.
* lisp/textmodes/css-mode.el (css-value-class-alist): Add `calc()' as
a completion candidate for several value classes.
(css--value-class-lookup): Return only unique results.
* test/lisp/textmodes/css-mode-tests.el
(css-test-property-values-no-duplicates)
(css-test-value-class-lookup): Update to reflect the above changes.
Paul Eggert [Tue, 26 Apr 2016 16:12:14 +0000 (09:12 -0700)]
Fix socketd fd startup bug that I introduced
Problem reported by Matthew Leach in:
http://lists.gnu.org/archive/html/emacs-devel/2016-04/msg00778.html
* src/emacs.c (main): Indicate more clearly the coupling between
the --daemon option and init_process_emacs.
* src/lisp.h: Adjust to API changes.
* src/process.c (set_external_socket_descriptor):
Remove, replacing by ...
(init_process_emacs): ... passing the socket FD here instead.
All uses changed.
Tao Fang [Mon, 25 Apr 2016 23:24:44 +0000 (01:24 +0200)]
Fix: (void-variable url-http-response-status)
* lisp/url/url-http.el
(url-https-proxy-after-change-function): Display the error
message before doing the callback to avoid a void variable
situation (bug#23290).
* lisp/mail/smtpmail.el (smtpmail-via-smtp): Move the sending
of the data end marker from here... (bug#23020).
(smtpmail-send-data): ... to here, so that we don't get a
"Sending done" before we've sent the final "." (which can make
the SMPT server reject the email.
Alan Mackenzie [Mon, 25 Apr 2016 17:57:24 +0000 (17:57 +0000)]
Fix spurious fontification of "for (; a * b;)" in CC Mode.
* lisp/progmodes/cc-fonts.el (c-font-lock-declarations): Check for being
inside the parens of a for statement and after a semicolon near the beginning
of the lambda form.
Paul Eggert [Mon, 25 Apr 2016 17:41:29 +0000 (10:41 -0700)]
New function ‘char-from-name’
This also fixes the mishandling of "\N{CJK COMPATIBILITY
IDEOGRAPH-F900}", "\N{VARIATION SELECTOR-1}", etc.
Problem reported by Eli Zaretskii in:
http://lists.gnu.org/archive/html/emacs-devel/2016-04/msg00614.html
* doc/lispref/nonascii.texi (Character Codes), etc/NEWS: Document this.
* lisp/international/mule-cmds.el (char-from-name): New function.
(read-char-by-name): Use it. Document that "BED" is treated as
a name, not as a hexadecimal number. Reject out-of-range integers,
floating-point numbers, and strings with trailing junk.
* src/lread.c (character_name_to_code): Call char-from-name
instead of inspecting ucs-names directly, so that we handle
computed names like "VARIATION SELECTOR-1". Do not use an auto
string, since char-from-name might GC.
* test/src/lread-tests.el: Add tests for new behavior, and
fix some old tests that were wrong.
; Run find-function-after-hook after finding a symbol
* lisp/emacs-lisp/find-func.el (find-library):
* lisp/help-mode.el (help-function-def, help-variable-def):
Run `find-function-after-hook' inside the help-function of the
buttons (bug#22583).
Alan Mackenzie [Mon, 25 Apr 2016 17:08:26 +0000 (17:08 +0000)]
c-forward-<>-arglist no longer directly applies face properties in Java Mode.
This allows the calling of c-restore-<>-properties from c-common-init without
the test suite giving spurious errors.
* lisp/progmodes/cc-engine.el (c-forward-<>-arglist): Remove the form that
sets face properties.
(c-forward-<>-arglist-recur): Reformulate the bit that handles types inside
template brackets using c-inside-<>-type-key. Don't bind
c-record-type-identifiers or c-record-found-types around the recursive call,
allowing positions of found types to flow back to the caller.
* lisp/progmodes/cc-langs.el (c-inside-<>-type-kwds, c-inside-<>-type-key):
new lang consts/var.
* lisp/progmodes/cc-mode.el (c-common-init): Don't remove
c-restore-<>-properties from the list of functions called at mode
initialization.
Alan Mackenzie [Mon, 25 Apr 2016 15:19:58 +0000 (15:19 +0000)]
Add fontification for a C declaration which looks like a function call.
For example, "t1 *fn (t2 *b);".
* lisp/progmodes/cc-engine.el (c-forward-decl-or-cast-1): Add new variable
at-decl-start, setting it to whether the putative decl starts immediately
after ; or { or }. Accept such a construct as a decl when at-decl-start is
non-nil.
* lisp/progmodes/cc-langs.el (c-pre-start-tokens): New language variable.
Eli Zaretskii [Mon, 25 Apr 2016 08:50:37 +0000 (11:50 +0300)]
Don't mirror slashes in convert-standard-filename on MS-Windows
* lisp/w32-fns.el (w32-convert-standard-filename): Don't mirror
slashes into backslashes. This avoids producing ugly file names,
and is deemed no longer necessary, and should certainly be
unrelated to which shell is in use.
Revert the disputed VC change and update the tests
* lisp/vc/vc-hooks.el (vc-working-revision):
Remove the previous change.
(vc-state): Same. And update the old, incorrect comment about
unregistered files
(http://lists.gnu.org/archive/html/emacs-devel/2016-04/msg00526.html).
* test/lisp/vc/vc-tests.el (vc-test--state): Remove the check
calling `vc-state' on default-directory (VC state is undefined
for directories). Check that `vc-state' returns nil where it
returned `unregistered' before. Remove all checks comparing
invocations with the backend passed in explictly and without.
(vc-test--working-revision): Remove all checks comparing
invocations with the backend passed in explictly and without.
Update comments, and add a new one.