Leo Liu [Mon, 13 May 2013 07:24:22 +0000 (15:24 +0800)]
* progmodes/octave.el (octave-indent-comment): Fix indentation for %!.
(octave-comment-start-skip): Include %!.
(octave-mode): Set comment-start-skip to octave-comment-start-skip.
Leo Liu [Sun, 12 May 2013 04:10:40 +0000 (12:10 +0800)]
* progmodes/octave.el (inferior-octave-startup): Store the value
of __octave_srcdir__ for octave-source-directories.
(inferior-octave-check-process): New function refactored out of
inferior-octave-send-list-and-digest.
(octave-source-directories)
(octave-find-definition-filename-function): New variables.
(octave-source-directories)
(octave-find-definition-default-filename): New functions.
(octave-find-definition): Improve to find functions implemented in C++.
Kevin Ryde [Sat, 11 May 2013 23:52:27 +0000 (16:52 -0700)]
Use generated-autoload-load-name for cus-load.el.
* lisp/cus-dep.el (custom-make-dependencies):
Use generated-autoload-load-name for the sake of files such
such cedet/semantic/bovine/c.el, where the base file name
is not in load-path.
Leo Liu [Sat, 11 May 2013 03:50:34 +0000 (11:50 +0800)]
* progmodes/octave.el (octave-beginning-of-line)
(octave-end-of-line): Check before using up-list because it jumps
out of more syntactic contructs since moving to smie.
Glenn Morris [Sat, 11 May 2013 02:25:11 +0000 (19:25 -0700)]
Make a few libraries loadable in isolation
* lisp/calc/calc-menu.el: Make it loadable in isolation.
* lisp/gnus/gnus-vm.el: Make it loadable without VM.
(gnus-vm-make-folder, gnus-summary-save-in-vm): Require 'vm.
(vm-forward-message, vm-reply, vm-mail): Remove unused autoloads.
* lisp/net/eudcb-bbdb.el: Make it loadable without bbdb.
(eudc-bbdb-filter-non-matching-record, eudc-bbdb-extract-phones)
(eudc-bbdb-extract-addresses, eudc-bbdb-format-record-as-result)
(eudc-bbdb-query-internal): Require 'bbdb.
Leo Liu [Fri, 10 May 2013 06:26:42 +0000 (14:26 +0800)]
* progmodes/octave.el (inferior-octave-completion-table): No
longer a function and all uses changed. Use cache to speed up
completion due to bug#11906.
(octave-beginning-of-defun): Re-write to be more general.
Stefan Monnier [Thu, 9 May 2013 18:30:46 +0000 (14:30 -0400)]
* src/doc.c (get_doc_string): Slightly relax the sanity checking.
* src/lread.c (skip_dyn_eof): New function.
(read1): Use it to skip the end of a file in response to #@00.
Stefan Monnier [Thu, 9 May 2013 17:54:29 +0000 (13:54 -0400)]
* lisp/comint.el (comint-redirect-send-command-to-process): Use :around
rather than :override for comint-redirect-filter.
(comint-redirect-filter): Add the corresponding `orig-filter' argument.
Call it instead of comint-redirect-original-filter-function (which
is gone). Reported by Juanma Barranquero <lekktu@gmail.com>.
Glenn Morris [Thu, 9 May 2013 06:09:39 +0000 (23:09 -0700)]
admin/cus-test,el misc updates
Mainly for some files listed in loaddefs.el now being in subdirs that
are not in load-path.
* admin/cus-test.el (cus-test-libs-noloads): Add dunnet in the defvar.
(dunnet): Don't always load it.
(viper-mode): Only set if interactive.
(cus-test-load-custom-loads): Load dunnet if necessary.
(cus-test-load-1): New macro, with common code from cus-test-load-libs
and cus-test-libs.
(cus-test-load-libs, cus-test-libs): Use cus-test-load-1 macro.
Update for cus-test-get-autoload-deps changed result.
(cus-test-get-autoload-deps): Simplify. Return file names as they
appear in loaddefs.el (directory parts are needed now that not all
lisp subdirs are in load-path).
(cus-test-deps): Explicitly skip dunnet.
Leo Liu [Thu, 9 May 2013 00:52:49 +0000 (08:52 +0800)]
* progmodes/octave.el (inferior-octave-completion-at-point):
Restore the broken file completion.
(inferior-octave-startup): Fix incorrect highlighting for the
first prompt.
Stefan Monnier [Wed, 8 May 2013 20:25:57 +0000 (16:25 -0400)]
* lisp/progmodes/ruby-mode.el: First cut at SMIE support.
(ruby-use-smie): New var.
(ruby-smie-grammar): New constant.
(ruby-smie--bosp, ruby-smie--implicit-semi-p)
(ruby-smie--forward-token, ruby-smie--backward-token)
(ruby-smie-rules): New functions.
(ruby-mode-variables): Setup SMIE if applicable.
* test/indent/ruby.rb: Fix indentation after =; add more cases.
Eli Zaretskii [Wed, 8 May 2013 18:05:40 +0000 (21:05 +0300)]
Avoid beginning/end of buffer errors when moving across display strings.
lisp/simple.el (line-move-visual): Signal beginning/end of buffer
only if vertical-motion moved less than it was requested. Avoids
silly incorrect error messages when there are display strings with
multiple newlines at EOL.
Eli Zaretskii [Wed, 8 May 2013 17:59:38 +0000 (20:59 +0300)]
Fix vertical cursor motion when there's a display string with newline at EOL.
src/xdisp.c (row_for_charpos_p): New function, with code of
cursor_row_p, but accepts an additional argument CHARPOS instead
of using a hardcoded PT.
(cursor_row_p): Call row_for_charpos_p with 2nd argument PT.
(row_containing_pos): Call row_for_charpos_p instead of partially
doing the same. Fixes cursor positioning under longlines-mode
when longlines-show-effect includes more than one newline, when
moving the cursor vertically up.
Stefan Monnier [Wed, 8 May 2013 16:27:53 +0000 (12:27 -0400)]
* lisp/progmodes/f90.el (f90-mode-syntax-table): Use symbol syntax for "_".
Change all regexps to use things like \_< and \_>.
* lisp/progmodes/ada-mode.el (ada-mode-abbrev-table): Consolidate declaration.
(ada-mode-syntax-table, ada-mode-symbol-syntax-table): Initialize in
the declaration.
(ada-create-syntax-table): Remove.
(ada-capitalize-word): Don't mess with the syntax of "_" since it
already has the right syntax nowadays.
(ada-goto-next-word): Don't change the syntax of "_".
* lisp/progmodes/autoconf.el (autoconf-definition-regexp)
(autoconf-font-lock-keywords, autoconf-current-defun-function):
Handle a _ with symbol syntax.
(autoconf-mode): Don't change the syntax-table for imenu and font-lock.
* lisp/progmodes/vera-mode.el (vera-underscore-is-part-of-word):
* lisp/progmodes/prolog.el (prolog-underscore-wordchar-flag)
(prolog-char-quote-workaround):
* lisp/progmodes/cperl-mode.el (cperl-under-as-char):
* lisp/progmodes/vhdl-mode.el (vhdl-underscore-is-part-of-word):
Mark as obsolete.
(vhdl-mode-syntax-table, vhdl-mode-ext-syntax-table): Initialize in
their declaration.
(vhdl-mode-syntax-table-init): Remove.
* lisp/progmodes/ld-script.el (ld-script-mode-syntax-table): Use symbol
syntax for "_".
(ld-script-font-lock-keywords):
Change regexps to use things like \_< and \_>.
* lisp/progmodes/m4-mode.el (m4-mode-syntax-table): Add comment on last change.
Sam Steingold [Wed, 8 May 2013 15:13:25 +0000 (11:13 -0400)]
* lisp/thingatpt.el (thing-at-point): Accept optional second argument
NO-PROPERTIES to strip the text properties from the return value.
* lisp/net/browse-url.el (browse-url-url-at-point): Pass NO-PROPERTIES
to `thing-at-point' instead of stripping the properties ourselves.
Also, when `thing-at-point' fails to find a url, prepend "http://"
to the filename at point on the assumption that the user is
pointing at something like gnu.org/gnu.
Leo Liu [Wed, 8 May 2013 14:22:24 +0000 (22:22 +0800)]
Re-work a fix for bug#10994 based on Le Wang's patch.
* ido.el (ido-remove-consecutive-dups): New helper.
(ido-completing-read): Use it.
(ido-chop): Revert fix for bug#10994.
Glenn Morris [Wed, 8 May 2013 06:56:37 +0000 (23:56 -0700)]
m4-mode misc small cleanup
* lisp/progmodes/m4-mode.el (m4-program): Assume it is in PATH.
(m4-mode-syntax-table): Init in the defvar.
(m4-mode-abbrev-table): Let define-derived-mode define it.
Paul Eggert [Tue, 7 May 2013 21:34:03 +0000 (14:34 -0700)]
Use Gnulib ACL implementation, for benefit of Solaris etc.
* configure.ac: Remove -with-acl option, since Gnulib does that for
us now.
(LIBACL_LIBS): Remove; no longer needed.
* lib/Makefile.am (CLEANFILES, SUFFIXES): New (empty) macros,
for the benefit of the new ACL implementation.
* lib/makefile.w32-in (GNULIBOBJS): Add $(BLD)/acl-errno-valid.$(O).
($(BLD)/acl-errno-valid.$(O)): New rule.
* lib/acl-errno-valid.c, lib/acl-internal.h, lib/acl.h:
* lib/acl_entries.c, lib/errno.in.h, lib/file-has-acl.c:
* lib/qcopy-acl.c, lib/qset-acl.c, m4/acl.m4, m4/errno_h.m4:
New files, taken from gnulib.
* lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate.
* admin/merge-gnulib (GNULIB_MODULES): Add qacl.
(GNULIB_TOOL_FLAGS): Do not avoid errno.
* etc/NEWS: Emacs is no longer limited to POSIX ACLs. --disable-acl,
not --without-acl, since we're now using Gnulib's implementation.
* nt/config.nt (HAVE_ACL_SET_FILE): Rename from HAVE_POSIX_ACL.
* nt/inc/ms-w32.h (EOPNOTSUPP): New macro.
* src/Makefile.in (LIB_ACL): New macro.
(LIBACL_LIBS): Remove.
(LIBES): Use LIB_ACL, not LIBACL_LIBS.
* src/fileio.c: Include <acl.h>.
Use HAVE_ACL_SET_FILE rather than HAVE_POSIX_ACL.
(ACL_NOT_WELL_SUPPORTED): Remove. All uses replaced by
!acl_errno_valid.
(Fcopy_file) [!WINDOWSNT]: Use qcopy_acl instead of rolling
it ourselves.
Paul Eggert [Tue, 7 May 2013 20:55:47 +0000 (13:55 -0700)]
* unexelf.c: Don't assume ElfW (Half) fits in int.
(entry_address, find_section, unexec): Use ptrdiff_t, not int,
when dealing with ElfW (Half) values, since they can exceed 2**31
on 64-bit OpenBSD hosts. Problem reported privately by Han Boetes.
(entry_address): Omit unused NUM arg. All uses changed.
Paul Eggert [Tue, 7 May 2013 05:34:01 +0000 (22:34 -0700)]
Static checking by GCC 4.8.0.
* xfns.c (x_get_net_workarea, struct MonitorInfo, free_monitors)
(x_get_monitor_for_frame, x_make_monitor_attribute_list)
(x_get_monitor_attributes_fallback)
(x_get_monitor_attributes_xinerama)
(x_get_monitor_attributes_xrandr, x_get_monitor_attributes):
Define only if USE_GTK.
(free_monitors): Define only if HAVE_XINERAMA || HAVE_XRANDR.
(x_get_monitor_attributes_fallback): Omit unused locals.
(x_get_monitor_attributes_xinerama, Fx_display_monitor_attributes_list):
Use double, not float, to avoid mixed-mode floating point arithmetic.
Leo Liu [Mon, 6 May 2013 23:46:07 +0000 (07:46 +0800)]
* progmodes/octave.el (octave-syntax-propertize-function): Change
\'s syntax to escape when inside double-quoted strings.
(octave-font-lock-keywords): Use octave-operator-regexp.
(octave-completion-at-point): Renamed from
octave-completion-at-point-function.
(inferior-octave-directory-tracker): Robustify.
(octave-text-functions): Remove and fix its uses. No such things
any more.
Stefan Monnier [Mon, 6 May 2013 19:33:56 +0000 (15:33 -0400)]
* lisp/progmodes/perl-mode.el: Add support for here documents.
(perl-syntax-propertize-function): Match here-doc markers.
(perl-syntax-propertize-special-constructs): Find their end.
(perl-imenu-generic-expression): Use [:alnum:].
Eli Zaretskii [Mon, 6 May 2013 17:11:07 +0000 (20:11 +0300)]
Fix bug #14241 with posn-at-point at the beginning of an image display prop.
src/xdisp.c (pos_visible_p): Use the special code for finding the
beginning of a display property or overlay for any "replacing"
display property, not just for display strings. This solves
incorrect reporting of position by posn-at-point.