2003-07-04 Stefan Monnier <monnier@cs.yale.edu>
+ * emacs-lisp/cl-macs.el (cl-transform-lambda): Strip &cl-defs
+ thingies from constructors created by defstruct.
+
+ * emacs-lisp/bytecomp.el (byte-compile-defvar): Check and set
+ the default value of the variable.
+ (byte-code-meter): Move declaration to top level.
+
+ * pcvs-parse.el (cvs-parse-status): Ignore extra fields from CVSNT.
+
+ * info.el (Info-following-node-name-re): New fun.
+ (Info-following-node-name): Remove.
+ (Info-insert-dir): Use the new fun.
+ (Info-extract-pointer): Don't save restriction; use new fun.
+ (Info-menu-entry-name-re): New const.
+ (Info-menu-entry-name-re): Use it along with new fun.
+ (Info-node-spec-re): Use new fun.
+ (Info-complete-menu-item, Info-fontify-node): Use new const.
+ (Info-goto-node, Info-follow-reference, Info-menu-update):
+ Use match-string.
+ (Info-follow-reference): Use assoc-string.
+ Use a list of strings for the completion table.
+ (Info-fontify-node): Use match-string, line-end-position.
+ Limit the search for `node:' to the first line.
+
+ * newcomment.el (uncomment-region): Remove padding coming from
+ comment-start rather than just from comment-padding.
+
+ * vc-cvs.el (vc-cvs-repository-hostname): New operation.
+ (vc-cvs-stay-local-p): Use vc-stay-local-p.
+ (vc-cvs-rename-file): Remove (use the default).
+ (vc-cvs-register): Register parent dir if needed.
+ (vc-cvs-could-register): Return non-nil if parent can be registered.
+ (vc-cvs-state, vc-cvs-dir-state, vc-cvs-print-log, vc-cvs-diff)
+ (vc-cvs-diff-tree, vc-cvs-make-version-backups-p): Use vc-stay-local-p.
+
+ * vc-svn.el (vc-svn-use-edit): Make it into a const.
+ (vc-svn-update): Fix the arguments to `svn'.
+ (vc-svn-diff-tree): Just use `vc-svn-diff'.
+ (vc-svn-create-snapshot, vc-svn-retrieve-snapshot):
+ Simple implementations, assuming `name' is a URL.
+
+ * progmodes/sh-script.el (sh-font-lock-paren): Add [ and ] to the
+ set of chars allowed unquoted in a case pattern.
+
* font-core.el (font-lock-defaults-alist): Remove obsolete entries.
* font-lock.el (font-lock-extra-types-widget)
2003-07-04 Martin Stjernholm <mast@lysator.liu.se>
- * generic-x.el: Did away with the dependency on `c-emacs-features'
+ * generic-x.el: Do away with the dependency on `c-emacs-features'
when populating `rul-generic-mode-syntax-table'; we already know
this isn't XEmacs.
* progmodes/cc-menus.el (cc-imenu-init): Do not set
`imenu-create-index-function' if the second argument is left
- out. This bug broke the imenu support in C, C++ and Java
- modes.
+ out. This bug broke the imenu support in C, C++ and Java modes.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-engine.el, progmodes/cc-align.el
- (c-add-stmt-syntax, c-lineup-arglist,
- c-lineup-arglist-close-under-paren): Fixes to cope with
+ (c-add-stmt-syntax, c-lineup-arglist)
+ (c-lineup-arglist-close-under-paren): Fixes to cope with
special brace lists in Pike.
2003-07-03 Alan Mackenzie <bug-cc-mode@gnu.org>
2003-07-03 Alan Mackenzie <bug-cc-mode@gnu.org>
- * progmodes/cc-awk.el, progmodes/cc-engine.el: Added code to
+ * progmodes/cc-awk.el, progmodes/cc-engine.el: Add code to
analyze AWK top-level forms properly (c-guess-basic-syntax
CASE 5P), c-awk-backward-syntactic-ws.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-langs.el (c-paren-nontype-kwds): New language
- constant.
+ * progmodes/cc-langs.el (c-paren-nontype-kwds): New language constant.
- (c-other-decl-kwds, c-postfix-decl-spec-kwds): Added compiler
+ (c-other-decl-kwds, c-postfix-decl-spec-kwds): Add compiler
specific declspec keywords: __attribute__ for gcc and
__declspec for msvc.
- * progmodes/cc-fonts.el (c-font-lock-declarations,
- c-complex-decl-matchers): Support specifiers in a couple more
+ * progmodes/cc-fonts.el (c-font-lock-declarations)
+ (c-complex-decl-matchers): Support specifiers in a couple more
contexts to cope with msvc '__declspec'.
- * progmodes/cc-engine.el (c-forward-keyword-clause): Support
- `c-paren-nontype-kwds'.
+ * progmodes/cc-engine.el (c-forward-keyword-clause):
+ Support `c-paren-nontype-kwds'.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-bytecomp.el (cc-bytecomp-setup-environment): Do
- not cover functions that have been bound.
+ * progmodes/cc-bytecomp.el (cc-bytecomp-setup-environment):
+ Do not cover functions that have been bound.
(cc-external-require): New macro to use for requiring external
packages, to handle the environment correctly.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-engine.el (c-beginning-of-member-init-list,
- c-guess-basic-syntax): Fixes in handling of bitfields.
+ * progmodes/cc-engine.el (c-beginning-of-member-init-list)
+ (c-guess-basic-syntax): Fixes in handling of bitfields.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-langs.el (comment-end): Put a space in front of
- the comment ender in C, as it was before the move from
- progmodes/cc-mode.el.
+ the comment ender in C, as it was before the move from cc-mode.el.
2003-07-03 Alan Mackenzie <bug-cc-mode@gnu.org>
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-mode.el (c-initialize-cc-mode): Added some
+ * progmodes/cc-mode.el (c-initialize-cc-mode): Add some
compatibility to make this function behave somewhat more as
documented for derived modes. It's still not enough to make
the old AWK mode behave reasonably, but it's been like this a
* progmodes/cc-fonts.el (c-remove-font-lock-face): New macro
to remove a font lock face properly (especially in XEmacs).
- * progmodes/cc-bytecomp.el (cc-bytecomp-obsolete-fun): Added
- the same kludge as in `cc-bytecomp-obsolete-var' to avoid a
+ * progmodes/cc-bytecomp.el (cc-bytecomp-obsolete-fun):
+ Add the same kludge as in `cc-bytecomp-obsolete-var' to avoid a
confused compiler warning.
- * progmodes/cc-engine.el (c-forward-type): Fixed a bug in the
- handling of concatenated types when the component types are
- known.
+ * progmodes/cc-engine.el (c-forward-type): Fix a bug in the
+ handling of concatenated types when the component types are known.
- * progmodes/cc-fonts.el (c-constant-face-name): Added face name variable to
- avoid the use of `font-lock-constant-face' for constants in
+ * progmodes/cc-fonts.el (c-constant-face-name): Add face name variable
+ to avoid the use of `font-lock-constant-face' for constants in
emacsen that doesn't have it.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-mode.el (c-basic-common-init): Use
- `open-paren-in-column-0-is-defun-start' if it exists and
- works.
+ * progmodes/cc-mode.el (c-basic-common-init):
+ Use `open-paren-in-column-0-is-defun-start' if it exists and works.
- * progmodes/cc-vars.el (c-emacs-features): Added `col-0-paren'
+ * progmodes/cc-vars.el (c-emacs-features): Add `col-0-paren'
to detect when `open-paren-in-column-0-is-defun-start' exists
and actually works.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-align.el (c-lineup-argcont,
- c-lineup-gcc-asm-reg): Don't quote nil in docstrings.
+ * progmodes/cc-align.el (c-lineup-argcont, c-lineup-gcc-asm-reg):
+ Don't quote nil in docstrings.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
the former a bit less hardcoded by putting it on
`c-font-lock-extra-types' instead. There are also "bool" and
"_Bool" that work the same way.
-
(c-constant-kwds): "false" and "true" are standard constant
macros in C99.
progmodes/cc-cmds.el: Fixed various regexps to use POSIX char
classes when that is supported.
- * progmodes/cc-defs.el (c-alpha, c-alnum, c-digit, c-upper,
- c-lower): New constants to make it easier to create regexps
+ * progmodes/cc-defs.el (c-alpha, c-alnum, c-digit, c-upper, c-lower):
+ New constants to make it easier to create regexps
that use POSIX char classes in emacsen that support them.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-mode.el (c-after-change): Added kludge for bug
+ * progmodes/cc-mode.el (c-after-change): Add kludge for bug
where this function sometimes gets positions outside the
buffer range.
* progmodes/cc-engine.el (c-beginning-of-member-init-list):
Better handling of paretheses in unexpected places.
- * progmodes/cc-engine.el (c-forward-<>-arglist-recur): Fixed a
+ * progmodes/cc-engine.el (c-forward-<>-arglist-recur): Fix a
regexp match order problem that could cause empty template
args on the form "<>" to be missed.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-engine.el (c-parse-state): Added kludge to
+ * progmodes/cc-engine.el (c-parse-state): Add kludge to
avoid an infinite loop when Emacs' open-paren-in-column-zero
rule kicks in and causes the sexp functions to misbehave.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-engine.el (c-beginning-of-member-init-list):
- Fixed bug when C++-like code is encountered in non-C++ mode.
+ Fix bug when C++-like code is encountered in non-C++ mode.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-defs.el (c-make-keywords-re): Added option to
+ * progmodes/cc-defs.el (c-make-keywords-re): Add option to
specify the language to look up `c-nonsymbol-key' in.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-langs.el (c-literal-start-regexp): Yet another
language variable.
- * progmodes/cc-fonts.el (c-font-lock-doc-comments,
- c-find-invalid-doc-markup, javadoc-font-lock-keywords): Fixed
- fontification of the markup in Javadoc comments.
+ * progmodes/cc-fonts.el (c-font-lock-doc-comments)
+ (c-find-invalid-doc-markup, javadoc-font-lock-keywords):
+ Fix fontification of the markup in Javadoc comments.
* progmodes/cc-engine.el: Fixes in face handling to cope with
doc comments.
faces at positions easier.
* progmodes/cc-defs.el (c-safe-scan-lists): New wrapper macro
- to avoid the warnings with too many args to `scan-lists' in
- Emacs.
+ to avoid the warnings with too many args to `scan-lists' in Emacs.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-engine.el (c-syntactic-skip-backward): New
- function to make syntactic searches in the backward direction
+ * progmodes/cc-engine.el (c-syntactic-skip-backward):
+ New function to make syntactic searches in the backward direction
easier.
- (c-beginning-of-statement-1): Optimized skipping over large paren
+ (c-beginning-of-statement-1): Optimize skipping over large paren
sexps somewhat.
- (c-safe-position): Removed the odd macro handling which was
+ (c-safe-position): Remove the odd macro handling which was
centered around the point instead of the passed position.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-engine.el (c-in-knr-argdecl): Do not trip up on
initialization expressions.
- * progmodes/cc-align.el (c-lineup-arglist,
- c-lineup-close-paren, c-lineup-arglist-close-under-paren):
- Tuned the "macro block" heuristics to work better in nested
+ * progmodes/cc-align.el (c-lineup-arglist)
+ (c-lineup-close-paren, c-lineup-arglist-close-under-paren):
+ Tune the "macro block" heuristics to work better in nested
arglist situations.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-mode.el (c-basic-common-init): Install
- `c-fill-paragraph' on `fill-paragraph-function'. Although
- it's not the normal way to call it in a CC Mode buffer it
+ * progmodes/cc-mode.el (c-basic-common-init):
+ Install `c-fill-paragraph' on `fill-paragraph-function'.
+ Although it's not the normal way to call it in a CC Mode buffer it
makes a direct call to `fill-paragraph' work better.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-vars.el, progmodes/cc-mode.el
- (c-require-final-newline): Made this variable an alist to
+ (c-require-final-newline): Make this variable an alist to
specify a value for each language. The default value causes
`require-final-newline' to be set to t only in languages where
the standard requires a final newline.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-mode.el, progmodes/cc-vars.el
- (c-require-final-newline): Added a variable to make the
+ (c-require-final-newline): Add a variable to make the
initialization of `require-final-newline' more configurable.
* progmodes/cc-vars.el (c-mode-common-hook): Do not change the
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-fonts.el (javadoc-font-lock-keywords,
- autodoc-font-lock-keywords): Support for Javadoc and Pike
+ * progmodes/cc-fonts.el (javadoc-font-lock-keywords)
+ (autodoc-font-lock-keywords): Support for Javadoc and Pike
Autodoc doc comments.
* progmodes/cc-vars.el (c-doc-comment-style): New variable to
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-cmds.el (c-guess-fill-prefix): Tuned the
+ * progmodes/cc-cmds.el (c-guess-fill-prefix): Tune the
heuristics of when to use `c-block-comment-prefix' for an
unclosed block comment.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-engine.el, progmodes/cc-langs.el
- (c-nonsymbol-sexp-kwds, c-forward-keyword-clause): Handle
- keywords like "extern" that can be followed by e.g. a string
+ (c-nonsymbol-sexp-kwds, c-forward-keyword-clause):
+ Handle keywords like "extern" that can be followed by e.g. a string
literal.
* progmodes/cc-defs.el (c-make-keywords-re): Make a regexp
- correctly with one submatch when adorn is set and the list is
- empty.
+ correctly with one submatch when adorn is set and the list is empty.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-fonts.el (c-font-lock-declarations): Fixed a
+ * progmodes/cc-fonts.el (c-font-lock-declarations): Fix a
search that could go far past the relevant region and cause
slowness. Do not limit the declaration detection to the
fontified region since that can cause misfontification in
multiline declarations.
- * progmodes/cc-engine.el (c-find-decl-spots): Added limit
+ * progmodes/cc-engine.el (c-find-decl-spots): Add limit
argument to handle declarations spanning the fontification
limit better.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-engine.el (c-in-literal, c-literal-limits,
- c-literal-limits-fast, c-beginning-of-inheritance-list): Use
- the paren cache instead of the impaired ad hoc in
+ * progmodes/cc-engine.el (c-in-literal, c-literal-limits)
+ (c-literal-limits-fast, c-beginning-of-inheritance-list):
+ Use the paren cache instead of the impaired ad hoc in
`beginning-of-defun', so that these functions doesn't trip up
on "{" in the first column inside strings or comments.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-vars.el (c-hanging-braces-alist): Added
- `statement-cont' and made it auto newline free by default.
+ * progmodes/cc-vars.el (c-hanging-braces-alist):
+ Add `statement-cont' and made it auto newline free by default.
- * progmodes/cc-cmds.el (c-electric-brace): Added
- `statement-cont' to the list of syntactic symbols to consider
- for auto newlines since it can be used for in-statement brace
- lists.
+ * progmodes/cc-cmds.el (c-electric-brace):
+ Add `statement-cont' to the list of syntactic symbols to consider
+ for auto newlines since it can be used for in-statement brace lists.
* progmodes/cc-vars.el (c-emacs-features): There's no need to
have this constant autoloaded.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-fonts.el (c-font-lock-declarations): Use
- `c-recognize-typeless-decls' to avoid fontifying some macro
+ * progmodes/cc-fonts.el (c-font-lock-declarations):
+ Use `c-recognize-typeless-decls' to avoid fontifying some macro
constructs as declarations in languages where a preceding type
is mandatory.
- * progmodes/cc-langs.el (c-recognize-typeless-decls): New
- language variable.
+ * progmodes/cc-langs.el (c-recognize-typeless-decls):
+ New language variable.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-align.el (c-lineup-close-paren): Use
- `c-syntactic-eol' when checking if the open paren ends its
- line.
+ * progmodes/cc-align.el (c-lineup-close-paren):
+ Use `c-syntactic-eol' when checking if the open paren ends its line.
* progmodes/cc-langs.el (c-syntactic-eol): Handle a line
continuation backslash.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-mode.el: Added autoload directives for the
+ * progmodes/cc-mode.el: Add autoload directives for the
interface functions in cc-langs.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-fonts.el (c-font-lock-declarations): Added a
+ * progmodes/cc-fonts.el (c-font-lock-declarations): Add a
property to handle refontication in multiline declaration
arglists better.
-
(c-font-lock-<>-arglists): Fix to handle recursive template
arglists better. (As a side effect this will make
fontification work better in older emacsen too.)
- * progmodes/cc-engine.el (c-forward-<>-arglist,
- c-remove-<>-arglist-properties): Use a common text property
+ * progmodes/cc-engine.el (c-forward-<>-arglist)
+ (c-remove-<>-arglist-properties): Use a common text property
`c-type' for all sorts of CC Mode char classification, to
avoid cases when then same char is given conflicting types.
-
(c-forward-<>-arglist): New reparse argument to control that
aspect explicitly.
-
(c-forward-name, c-forward-type): Changes in the handling of
recursive template arglists. Fixes to cope with the new 'known
type classification.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-mode.el (c-basic-common-init): Added the new
+ * progmodes/cc-mode.el (c-basic-common-init): Add the new
char property `c-type' to `text-property-default-nonsticky'.
- * progmodes/cc-defs.el (c-put-char-property,
- c-get-char-property, c-clear-char-property,
- c-clear-char-properties): Generalized `c-put-char-syntax' and
+ * progmodes/cc-defs.el (c-put-char-property)
+ (c-get-char-property, c-clear-char-property)
+ (c-clear-char-properties): Generalize `c-put-char-syntax' and
`c-get-char-syntax' to handle any property.
- * progmodes/cc-bytecomp.el (cc-bytecomp-defun): Fixed bug that
+ * progmodes/cc-bytecomp.el (cc-bytecomp-defun): Fix bug that
caused existing function definitions to be overridden by
phonies when the bytecomp environment is restored.
* progmodes/cc-cmds.el (c-mask-paragraph): Masking is
necessary in normal code too to avoid getting a fill prefix
- from a nearby comment. Changed the name from `c-mask-comment'
+ from a nearby comment. Change the name from `c-mask-comment'
to a more accurate one.
- * progmodes/cc-defs.el, progmodes/cc-mode.el: Changed the
+ * progmodes/cc-defs.el, progmodes/cc-mode.el: Change the
auto-load-alist strategy to not add entries on package load,
to be defensive in the case that autoloads are updated in
older emacsen. The bug that would occur in that case would
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-fonts.el (c-font-lock-declarations): Fine
- tuning of the decision tree that tells declarations from
+ * progmodes/cc-fonts.el (c-font-lock-declarations):
+ Fine tuning of the decision tree that tells declarations from
expressions to produce better results in some ambiguous cases.
* progmodes/cc-fonts.el (c-font-lock-syntactic-face-function):
- Removed since it doesn't give the control we want.
-
+ Remove since it doesn't give the control we want.
(c-font-lock-invalid-string): Replacement for
`c-font-lock-syntactic-face-function' that puts the error face
on the string opener only, to avoid the annoying excessive use
of the error face while a string literal is being written.
-
(c-basic-matchers-before): Use `c-font-lock-invalid-string'.
- * progmodes/cc-engine.el (c-string-syntax,
- c-string-limit-regexp): Added constants to use when handling
+ * progmodes/cc-engine.el (c-string-syntax)
+ (c-string-limit-regexp): Add constants to use when handling
string limits, since not all old emacsen react well to the "|"
syntax class.
- (c-literal-limits, c-literal-limits-fast, c-literal-type): Use
- `c-string-syntax' and `c-string-limit-regexp'. Replaced some
+ (c-literal-limits, c-literal-limits-fast, c-literal-type):
+ Use `c-string-syntax' and `c-string-limit-regexp'. Replace some
hardcoded comment start regexps with `c-comment-start-regexp'.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-mode.el: Add the `auto-mode-alist' entries to
the end instead of the start of the list, to avoid overriding
user additions that are made before this file is loaded when
- the entries don't correspond to any already on
- `auto-mode-alist'.
-
+ the entries don't correspond to any already on `auto-mode-alist'.
This is done through the third append argument to
- `auto-mode-alist'. That doesn't exist in older (X)Emacsen, so
- the function is adviced in cc-defs. However, that advice
+ `add-to-alist'. That doesn't exist in older (X)Emacsen, so
+ the function is advised in cc-defs. However, that advice
doesn't help if the autoloads are updated in an old (X)Emacs
with this version of CC Mode, but I believe it's unlikely that
anyone does that when CC Mode isn't distributed with with it.
- * progmodes/cc-defs.el (add-to-list): Added advice to get the
+ * progmodes/cc-defs.el (add-to-list): Add advice to get the
optional third append argument in older (X)Emacsen.
* progmodes/cc-langs.el (c-keywords-obarray): Kludge for
strange bug in Emacs that gives so odd errors that I frankly
- don't even muster to begin trying to narrow it down. If
- someone is so inclined, restore the commented code, byte
- compile, and try to open a C++ file or something in font lock
- mode.
+ don't even muster to begin trying to narrow it down.
+ If someone is so inclined, restore the commented code, byte
+ compile, and try to open a C++ file or something in font lock mode.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-langs.el: Updated the IDL support from the
+ * progmodes/cc-langs.el: Update the IDL support from the
specs. This also adds the keywords for the variants PSDL and
CIDL. (This is mostly done from reading the grammars only;
very lightly tested.)
- * progmodes/cc-langs.el (c-type-list-kwds): Added "new" in
- Java.
+ * progmodes/cc-langs.el (c-type-list-kwds): Add "new" in Java.
- * progmodes/cc-fonts.el: Made sure that
+ * progmodes/cc-fonts.el: Make sure that
`parse-sexp-lookup-properties' is properly insulated from
- clobbering by the font-lock package at all relevant entry
- points.
+ clobbering by the font-lock package at all relevant entry points.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-langs.el (c-opt-after-id-concat-key): New
- language constant to make the recognition of identifier
+ * progmodes/cc-langs.el (c-opt-after-id-concat-key):
+ New language constant to make the recognition of identifier
qualifiers more flexible. Recognize the identifier before
".*" as a qualifier in Java.
-
(c-identifier-key): Recognize "::*" inside identifiers in C++.
Recognize identifiers ending with ".*" in Java for the sake of
import directives.
-
(c-type-list-kwds, c-ref-list-kwds): Recognize "import" and
"package" declarations in Java.
- * progmodes/cc-vars.el (c-doc-face, c-doc-marker-face,
- c-doc-markup-face): Removed since they aren't used (and
+ * progmodes/cc-vars.el (c-doc-face, c-doc-marker-face)
+ (c-doc-markup-face): Remove since they aren't used (and
probably won't be).
* progmodes/cc-langs.el (c-ref-list-kwds): New language
constant to specify keywords followed by references.
-
(c-last-identifier-range): New variable to avoid going back to
search for the identifier to font lock after a call to
`c-forward-name'.
-
- (c-type-prefix-kwds, c-type-list-kwds): Fixed classification of
+ (c-type-prefix-kwds, c-type-list-kwds): Fix classification of
"@interface" etc in Objective-C.
- * progmodes/cc-engine.el (c-forward-keyword-clause): Fixed
- handling of keyword prefixes in `c-type-list-kwds' and
+ * progmodes/cc-engine.el (c-forward-keyword-clause):
+ Fix handling of keyword prefixes in `c-type-list-kwds' and
`c-colon-type-list-kwds' clauses.
-
(c-keyword-sym, c-keyword-member): New functions to lookup and
categorize keywords.
-
(c-forward-keyword-clause): New function to move over a keyword
and its associated clause according to `c-<>-arglist-kwds' etc.
- * progmodes/cc-langs.el (c-typeless-decl-kwds,
- c-type-list-kwds, c-colon-type-list-kwds,
- c-colon-type-list-re, c-paren-type-kwds): New language
+ * progmodes/cc-langs.el (c-typeless-decl-kwds)
+ (c-type-list-kwds, c-colon-type-list-kwds)
+ (c-colon-type-list-re, c-paren-type-kwds): New language
constants and variables to generalize the recognition of
various language constructs.
-
- (c-keywords): Did away with the list of `*-kwds' constants. It's
- now built through macro expansion.
-
+ (c-keywords): Did away with the list of `*-kwds' constants.
+ It's now built through macro expansion.
(c-keywords-obarray): New language variable which contains each
keyword as a symbol, to make fast reverse lookup of keywords to
the `*-kwds' lists they come from.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-defs.el (c-lang-defconst-eval-immediately):
- Added macro to be able to do direct evaluation in
+ Add macro to be able to do direct evaluation in
`c-lang-defconst' forms.
* progmodes/cc-engine.el (c-syntactic-re-search-forward):
- Fixed a bug which could cause the point to end up outside the
+ Fix a bug which could cause the point to end up outside the
containing sexp if PAREN-LEVEL was used.
* progmodes/cc-engine.el, progmodes/cc-fonts.el,
- progmodes/cc-langs.el: Generalized the C++ template arglist
+ progmodes/cc-langs.el: Generalize the C++ template arglist
support to handle angle bracket arglists in any language.
-
- (c-recognize-<>-arglists, c-<>-arglist-kwds,
- c-opt-<>-arglist-start): New language variables to control
+ (c-recognize-<>-arglists, c-<>-arglist-kwds)
+ (c-opt-<>-arglist-start): New language variables to control
angle bracket arglists.
-
(c-opt-type-suffix-key): Use `c-recognize-<>-arglists' in
Objective-C instead of matching a protocol reference list as a
type suffix.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-align.el (c-gnu-impose-minimum): Fixed a missing
+ * progmodes/cc-align.el (c-gnu-impose-minimum): Fix a missing
`save-excursion' that caused the point to jump around.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-mode.el, progmodes/cc-menus.el (objc-mode,
- cc-imenu-init): Fixed initialization bug that has made the
+ * progmodes/cc-mode.el, progmodes/cc-menus.el (objc-mode)
+ (cc-imenu-init): Fix initialization bug that has made the
Objective-C support inoperational since 5.26.
-
- (cc-imenu-objc-generic-expression): Updated submatch indices
+ (cc-imenu-objc-generic-expression): Update submatch indices
due to changes in `cc-imenu-c++-generic-expression'.
-
(cc-imenu-objc-function): Don't add an empty "C" menu since
imenu doesn't like that.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-align.el (c-lineup-arglist,
- c-lineup-arglist-close-under-paren, c-lineup-close-paren):
- Added DWIM to the functions that line up at or after the
+ * progmodes/cc-align.el (c-lineup-arglist)
+ (c-lineup-arglist-close-under-paren, c-lineup-close-paren):
+ Add DWIM to the functions that line up at or after the
arglist open paren to avoid that if there are brace blocks
inside, e.g. when a macro contains a code block.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-vars.el (objc-font-lock-extra-types): Changed
- default to treat identifiers starting with capital letters as
+ * progmodes/cc-vars.el (objc-font-lock-extra-types):
+ Change default to treat identifiers starting with capital letters as
types, according to Objective-C naming conventions. The types
previously on the list is part of the language and therefore
on `c-primitive-type-kwds' instead.
- * progmodes/cc-fonts.el: Fixed font locking in Objective-C.
+ * progmodes/cc-fonts.el: Fix font locking in Objective-C.
Be more careful about returning nil from functions used
directly as font-lock matchers.
- * progmodes/cc-mode.el (c-font-lock-init): Made the syntax
+ * progmodes/cc-mode.el (c-font-lock-init): Make the syntax
table modification element of `font-lock-defaults'
parameterized over the languages.
- * progmodes/cc-langs.el: Updated the Objective-C constants
+ * progmodes/cc-langs.el: Update the Objective-C constants
according to the language spec. The "@" chars that start
directives are now considered part of the keywords to make
things easier.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-defs.el: (c-(up|down)-list-(forward|backward)):
- Made the position optional and added docstrings.
+ Make the position optional and added docstrings.
- (c-go-(up|down)-list-(forward|backward)): Added variants of the
+ (c-go-(up|down)-list-(forward|backward)): Add variants of the
above that move point and return successfulness instead.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-fonts.el (c-font-lock-<>-arglists): New
- function to fontify all occurrences of template arglists in
- C++.
+ * progmodes/cc-fonts.el (c-font-lock-<>-arglists):
+ New function to fontify all occurrences of template arglists in C++.
* progmodes/cc-engine.el (c-disallow-comma-in-<>-arglists):
New variable to be able to avoid false recognition of template
* progmodes/cc-fonts.el, progmodes/cc-langs.el
(c-decl-prefix-re, c-font-lock-declarations): Match template
- open brackets to get a declaration in the first template
- argument.
-
+ open brackets to get a declaration in the first template argument.
(c-complex-decl-matchers): Fontify the second type in a "class
X = Y" expression in C++.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-engine.el (c-forward-<>-arglist): Broke out the
+ * progmodes/cc-engine.el (c-forward-<>-arglist): Break out the
recursive part to a new function to improve efficiency when a
nested template arglist search turns out to be futile.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-menus.el (cc-imenu-java-generic-expression):
- Improved to avoid false matches on e.g. "else if (foo)".
+ Improve to avoid false matches on e.g. "else if (foo)".
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-engine.el (c-forward-token-2,
- c-backward-token-2): New functions that work like the -1
- variants but that handles multicharacter operator tokens.
+ * progmodes/cc-engine.el (c-forward-token-2)
+ (c-backward-token-2): New functions that work like the -1
+ variants but that handle multicharacter operator tokens.
- * progmodes/cc-engine.el (c-inside-bracelist-p,
- c-guess-basic-syntax): Did away with the hardcoded regexps to
+ * progmodes/cc-engine.el (c-inside-bracelist-p)
+ (c-guess-basic-syntax): Do away with the hardcoded regexps to
recognize "typedef" declaration prefixes, "extern" and
"namespace" blocks, "enum"-style brace list declarations and
Java-style array initializers with "new".
- * progmodes/cc-langs.el (c-brace-list-decl-kwds,
- c-brace-list-key, c-inexpr-brace-list-kwds,
- c-opt-inexpr-brace-list-key): New language constants and
+ * progmodes/cc-langs.el (c-brace-list-decl-kwds)
+ (c-brace-list-key, c-inexpr-brace-list-kwds)
+ (c-opt-inexpr-brace-list-key): New language constants and
variables to parameterize some more of the hardcoded regexps
in cc-engine.
initializes the language variables. It's necessary that the
caller does that directly since the evaluated values for them
now get compiled in directly.
-
- (c-font-lock-init, c-common-init): Separated the font-lock
+ (c-font-lock-init, c-common-init): Separate the font-lock
initialization from `c-common-init'.
* progmodes/cc-mode.el (c-define-abbrev-table): Do not
override an existing abbrev table.
-
- (c-Java-defun-prompt-regexp): Moved here from cc-langs since
+ (c-Java-defun-prompt-regexp): Move here from cc-langs since
cc-langs isn't always loaded at runtime.
- * progmodes/cc-langs.el (c-make-init-lang-vars-fun,
- c-init-language-vars): Changed to allow language variable
+ * progmodes/cc-langs.el (c-make-init-lang-vars-fun)
+ (c-init-language-vars): Change to allow language variable
initialization from derived modes.
-
(c-mode-menu): New language variable for the mode menu.
-
- (c-make-mode-syntax-table, c-mode-syntax-table,
- make-c++-template-syntax-table): New language variables for syntax
+ (c-make-mode-syntax-table, c-mode-syntax-table)
+ (make-c++-template-syntax-table): New language variables for syntax
tables. The code that initializes them has been moved to cc-mode
to make it possible to avoid loading cc-langs at runtime.
* progmodes/cc-engine.el, progmodes/cc-langs.el
(c-hungry-delete-key, c-auto-newline, c-auto-hungry-string):
- Moved these state variables from cc-langs to cc-engine to make
+ Move these state variables from cc-langs to cc-engine to make
it possible to avoid loading cc-langs at runtime.
- * progmodes/cc-defs.el (c-lang-defconst, c-lang-const): Moved
- from cc-langs and rewritten to make the language constant
+ * progmodes/cc-defs.el (c-lang-defconst, c-lang-const):
+ Move from cc-langs and rewritten to make the language constant
system usable from derived modes.
(c-add-language): New function intended for use from derived modes
that add new C-like languages.
* progmodes/cc-defs.el, progmodes/cc-vars.el
- (c-buffer-is-cc-mode): Moved from cc-vars to cc-defs to define
+ (c-buffer-is-cc-mode): Move from cc-vars to cc-defs to define
it during compilation.
- * progmodes/cc-bytecomp.el (cc-require-when-compile): New
- support macro for compile time `require's.
+ * progmodes/cc-bytecomp.el (cc-require-when-compile):
+ New support macro for compile time `require's.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-defs.el, progmodes/cc-mode.el (c-version):
- Moved from cc-mode to cc-defs to make it accessible to the
+ Move from cc-mode to cc-defs to make it accessible to the
other components.
- * progmodes/cc-engine.el (c-forward-token-1,
- c-backward-token-1): Compatibility fix for emacsen that
- doesn't understand generic string delimiters.
+ * progmodes/cc-engine.el (c-forward-token-1, c-backward-token-1):
+ Compatibility fix for emacsen that doesn't understand generic
+ string delimiters.
- * progmodes/cc-vars.el (c-emacs-features): Added detection of
+ * progmodes/cc-vars.el (c-emacs-features): Add detection of
generic string and comment delimiters.
* progmodes/cc-defs.el, progmodes/cc-langs.el
- (c-make-keywords-re): Changed interface to make it more
- extensible.
+ (c-make-keywords-re): Change interface to make it more extensible.
- * progmodes/cc-langs.el, progmodes/cc-defs.el (c-regexp-opt,
- c-regexp-opt-depth, c-make-keywords-re): Moved from cc-langs
+ * progmodes/cc-langs.el, progmodes/cc-defs.el (c-regexp-opt)
+ (c-regexp-opt-depth, c-make-keywords-re): Move from cc-langs
to cc-defs since they are generally useful.
* progmodes/cc-bytecomp.el, progmodes/cc-defs.el
- (cc-eval-when-compile): Moved from cc-bytecomp to cc-defs to
+ (cc-eval-when-compile): Move from cc-bytecomp to cc-defs to
allow use at runtime.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-bytecomp.el (cc-eval-when-compile): Workaround
- for a bug with nested `eval-when-compile' in XEmacs 21.
+ * progmodes/cc-bytecomp.el (cc-eval-when-compile):
+ Workaround for a bug with nested `eval-when-compile' in XEmacs 21.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-align.el (c-lineup-cascaded-calls): Handle "."
too, for use in Java.
- * progmodes/cc-engine.el (c-forward-sws, c-backward-sws): Do
- not handle cpp directives in languages that doesn't have any.
+ * progmodes/cc-engine.el (c-forward-sws, c-backward-sws):
+ Do not handle cpp directives in languages that doesn't have any.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-langs.el (c-operators): Added a high level
- description of all operators, along with their precedence and
- associativity.
+ * progmodes/cc-langs.el (c-operators): Add a high level description
+ of all operators, along with their precedence and associativity.
- * progmodes/cc-align.el (c-lineup-multi-inher): Fixed bug
+ * progmodes/cc-align.el (c-lineup-multi-inher): Fix bug
where the position of the point and not the beginning of the
line was used to calculate the indentation.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-defs.el, progmodes/cc-engine.el
- (c-backward-single-comment, c-backward-comments): Added kludge
+ (c-backward-single-comment, c-backward-comments): Add kludge
for the bug in `forward-comment' in most (X)Emacs versions
where it moves back over the "*/" of a block comment if
there's no matching "/*". This has become more important now
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-cmds.el (c-hungry-backspace,
- c-hungry-delete-forward): New functions to do hungry deletion
+ * progmodes/cc-cmds.el (c-hungry-backspace)
+ (c-hungry-delete-forward): New functions to do hungry deletion
regardless of hungry-delete mode. Contributed by Kevin Ryde.
- * progmodes/cc-engine.el (c-forward-sws, c-backward-sws,
- c-invalidate-sws-region): Use text properties to cache regions
+ * progmodes/cc-engine.el (c-forward-sws, c-backward-sws)
+ (c-invalidate-sws-region): Use text properties to cache regions
with complex syntactic whitespace. This helps a lot in
improving responsiveness when there are lots of comments and
cpp directives before point.
progmodes/cc-menus.el, progmodes/cc-mode.el,
progmodes/cc-styles.el, progmodes/cc-vars.el,
progmodes/cc-engine.el, progmodes/cc-fonts.el,
- progmodes/cc-cmds.el, progmodes/cc-defs.el: Introduced a
+ progmodes/cc-cmds.el, progmodes/cc-defs.el: Introduce a
classification of functions into those that make "hidden
buffer changes" and those who don't. This is prompted by the
increasing use of text properties for various things, to
correctly cover the silly buffer modifications that is caused
by text property changes.
-
(c-save-buffer-state): New macro that's put around any code that
can manipulate text properties.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-mode.el (c-basic-common-init): Setup
- `text-property-default-nonsticky' to avoid messing with the
+ * progmodes/cc-mode.el (c-basic-common-init):
+ Setup `text-property-default-nonsticky' to avoid messing with the
rear-nonsticky property on each character in Emacs 21.
- * progmodes/cc-defs.el (c-clear-char-syntax,
- c-put-char-syntax): Macros that sets and removes the
+ * progmodes/cc-defs.el (c-clear-char-syntax, c-put-char-syntax):
+ Macros that sets and removes the
syntax-table property on a single character and makes the
property nonsticky in both directions in a suitable way for
each (X)Emacs flavor.
* progmodes/cc-vars.el, progmodes/cc-defs.el,
- progmodes/cc-engine.el, progmodes/cc-mode.el: Use
- `lookup-syntax-properties' in XEmacs to control whether the
+ progmodes/cc-engine.el, progmodes/cc-mode.el:
+ Use `lookup-syntax-properties' in XEmacs to control whether the
syntax-table property has any effect or not.
(c-parse-sexp-lookup-properties): New macro that expands to either
and XEmacs now.
* progmodes/cc-engine.el (c-forward-sws, c-backward-sws):
- Implemented a cache for the last large skipped over syntactic
+ Implement a cache for the last large skipped over syntactic
whitespace. This also has most effect after many macros.
* progmodes/cc-engine.el, progmodes/cc-defs.el
(c-forward-syntactic-ws, c-backward-syntactic-ws): Utilize the
limit better when one is passed. These are now macros to
avoid a little overhead when no limit is given.
-
(c-forward-sws, c-backward-sws): New functions called by the
macros above to do the unbounded search.
* progmodes/cc-fonts.el (c-font-lock-declarations):
- Implemented a cache for the first backward search for a
+ Implement a cache for the first backward search for a
preceding `c-decl-prefix-re' match. This typically speeds up
interactive refontification a lot on the top level of macro
heavy header files.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-vars.el (c-emacs-features): Added check for
+ * progmodes/cc-vars.el (c-emacs-features): Add check for
syntax text properties.
* progmodes/cc-mode.el (c-basic-common-init): Turn on
`parse-sexp-lookup-properties' if it's supported. Define the
- variable in any case since it's used at runtime to check on
- this.
+ variable in any case since it's used at runtime to check on this.
* progmodes/cc-langs.el (c-identifier-key): Support C++
destructor names.
-
- (c-identifier-start, c-op-token-regexp, c-type-modifier-kwds,
- c-opt-type-modifier-key, c-opt-type-component-key,
- c-typedef-specifier-kwds, c-typedef-specifier-key,
- c-paren-stmt-kwds, c-paren-stmt-key, c-syntactic-ws-start): A
- bunch of new language constants and variables to support the
+ (c-identifier-start, c-op-token-regexp, c-type-modifier-kwds)
+ (c-opt-type-modifier-key, c-opt-type-component-key)
+ (c-typedef-specifier-kwds, c-typedef-specifier-key)
+ (c-paren-stmt-kwds, c-paren-stmt-key, c-syntactic-ws-start):
+ A bunch of new language constants and variables to support the
improved handling of names and types.
- * progmodes/cc-fonts.el (c-font-lock-declarators,
- c-font-lock-declarations): Handle C++ template declarations
+ * progmodes/cc-fonts.el (c-font-lock-declarators)
+ (c-font-lock-declarations): Handle C++ template declarations
and template references. Fontify complex types and names more
accurately by delegating it to `c-forward-type' and
`c-forward-name'. Fontify the identifiers in typedef
to move forward over a C++ template arglist. It also marks
the '<' and '>' chars with paren syntax using the syntax-table
property, to speed up later calls in emacsen that support
- syntax text properties (Emacs >= 20 and (undocumented) XEmacs
- 21).
-
+ syntax text properties (Emacs >= 20 and (undocumented) XEmacs 21).
This also has the very interesting effect that if font locking
is used with decoration level 3 or higher in these emacsen
then template arglists will behave just like paren sexps with
the various sexp movement commands.
-
(c-forward-name): New function to move over a name. Simple in
most languages except C++ where a name can contain template
arglists and therefore almost arbitrary expressions.
-
(c-on-identifier): Fix for Pike operator identifiers.
+ (c-simple-skip-symbol-backward, c-syntactic-content)
+ (c-remove-<>-paren-properties): New helper functions.
- (c-simple-skip-symbol-backward, c-syntactic-content,
- c-remove-<>-paren-properties): New helper functions.
-
- * progmodes/cc-defs.el: (c-clear-char-syntax,
- c-mark-paren-open, c-mark-paren-close): New support functions
- to handle syntactic properties on C++ template arglist
- brackets.
-
+ * progmodes/cc-defs.el: (c-clear-char-syntax)
+ (c-mark-paren-open, c-mark-paren-close): New support functions
+ to handle syntactic properties on C++ template arglist brackets.
(c-put-type-face, c-put-reference-face): Helpers to put faces on
regions, since there are a bit of that inside `c-forward-name' etc
in progmodes/cc-engine.el.
* progmodes/cc-engine.el, progmodes/cc-fonts.el,
- progmodes/cc-langs.el: Fixed the names on a number of regexp
+ progmodes/cc-langs.el: Fix the names on a number of regexp
language variables to conform to the nomenclature and
shortened some names.
* progmodes/cc-align.el, progmodes/cc-cmds.el,
progmodes/cc-fonts.el, progmodes/cc-engine.el
- (c-syntactic-re-search-forward): Removed the COUNT argument
- since it's never used. Added an argument to tell which
+ (c-syntactic-re-search-forward): Remove the COUNT argument
+ since it's never used. Add an argument to tell which
subexpression whose end should be tested for syntactic
relevance. Using this also removes some optimizations, so
that it's possible to use a look behind subexpression that
(c-guess-continued-construct): Don't match <<= or >>= for the
stream-op syntactic element.
- * progmodes/cc-defs.el (c-paren-re, c-identifier-re): Removed
- these helper macros since better and more correct tools are
+ * progmodes/cc-defs.el (c-paren-re, c-identifier-re):
+ Remove these helper macros since better and more correct tools are
now available in progmodes/cc-langs.el.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-langs.el (c-populate-syntax-table): XEmacs
- classifies the hard space character as a symbol character but
- it's better to let it be in the punctuation class so that it's
+ * progmodes/cc-langs.el (c-populate-syntax-table):
+ XEmacs classifies the hard space character as a symbol character
+ but it's better to let it be in the punctuation class so that it's
always highlighted with the inverted invalid face. It can
perhaps be argued that that character is allowed in
identifiers in some languages (haven't checked), but using it
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-engine.el (c-beginning-of-statement-1): Fixed a
+ * progmodes/cc-engine.el (c-beginning-of-statement-1): Fix a
case when a labeled substatement caused incorrect association
of the following continuation clause.
(c-guess-continued-construct): Analyze the "K&R region" of a
function nested inside a function as func-decl-cont and not
- statement-cont. New case E. Also cleaned up case C (stream-op
+ statement-cont. New case E. Also clean up case C (stream-op
recognition) a bit.
* progmodes/cc-engine.el (c-parse-state, c-check-state-cache):
- Moved the check on `c-state-cache-start' from
+ Move the check on `c-state-cache-start' from
`c-check-state-cache' to `c-parse-state' so that the state
cache isn't zapped if `c-check-state-cache' but not
- `c-parse-state' is called during a temporary narrowing. This
- fixes a performance problem that could occur when
+ `c-parse-state' is called during a temporary narrowing.
+ This fixes a performance problem that could occur when
`fill-paragraph' is used in font lock mode on a comment at the
end of a large class or function.
- (c-state-cache-start): Fixed buffer localness.
+ (c-state-cache-start): Fix buffer localness.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-langs.el: Updated the keywords and operator
+ * progmodes/cc-langs.el: Update the keywords and operator
tokens from the latest C++ and Java standards. Some other
multichar token corrections.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-cmds.el, progmodes/cc-engine.el,
- progmodes/cc-vars.el (c-syntactic-context,
- c-syntactic-element): Do not bind any values to these
+ progmodes/cc-vars.el (c-syntactic-context)
+ (c-syntactic-element): Do not bind any values to these
variables globally since they should always be dynamically
bound. This makes it much easier to debug cases when they've
gotten global values somehow.
* progmodes/cc-langs.el (c-regexp-opt): Fix to work around the
non-greedy behavior that the regexp engine sometimes exposes.
- This bug only shows in (X)Emacs 19 where there's no regexp-opt
- package.
+ This bug only shows in (X)Emacs 19 where there's no regexp-opt package.
* progmodes/cc-engine.el (c-syntactic-re-search-forward):
- Added a feature to filter out matches in the middle of tokens.
+ Add a feature to filter out matches in the middle of tokens.
Changed the comment to a docstring since I consider this
function generally useful.
- * progmodes/cc-defs.el (c-mode-symbol): Broke out a part of
+ * progmodes/cc-defs.el (c-mode-symbol): Break out a part of
`c-mode-var'.
- * progmodes/cc-align.el (c-lineup-cascaded-calls,
- c-lineup-gcc-asm-reg): Cope with that `c-most-enclosing-brace'
+ * progmodes/cc-align.el (c-lineup-cascaded-calls)
+ (c-lineup-gcc-asm-reg): Cope with that `c-most-enclosing-brace'
might return nil.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-engine.el (c-found-types, c-clear-found-types,
- c-add-type, c-check-type, c-add-complex-type,
- c-list-found-types, c-forward-type): Added a sort of symbol
+ * progmodes/cc-engine.el (c-found-types, c-clear-found-types)
+ (c-add-type, c-check-type, c-add-complex-type)
+ (c-list-found-types, c-forward-type): Add a sort of symbol
table for types: If a name is recognized as a type in a
declaration it's added in an obarray to be able to recognize
it in other ambiguous declarations.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-engine.el (c-forward-syntactic-ws): Fixed a bug
+ * progmodes/cc-engine.el (c-forward-syntactic-ws): Fix a bug
that could cause an infinite loop if something that looks like
a macro begins in the middle of a line.
- (c-parse-state): Fixed a bug that could cause `c-state-cache'
+ (c-parse-state): Fix a bug that could cause `c-state-cache'
to contain two conses in sequence when there's an unbalanced
open paren in a macro.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-defs.el (c-face-name-p): A defsubst to
- recognize the name of a face in a way that works also in
- XEmacs.
+ recognize the name of a face in a way that works also in XEmacs.
* progmodes/cc-engine.el (c-forward-type): New function to
move past a type spec.
* progmodes/cc-engine.el (c-syntactic-re-search-forward):
- Fixed behavior when the limit is reached inside a comment,
+ Fix behavior when the limit is reached inside a comment,
string, or a macro.
* progmodes/cc-align.el, progmodes/cc-cmds.el,
four different cases it's actually used. These replacements
also treats line continuations as whitespace.
- (c-forward-comment): Removed. The four different cases above
+ (c-forward-comment): Remove. The four different cases above
are basically different, so it's better to make them into
separate functions than choose between them at runtime using
the argument.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-align.el (c-gnu-impose-minimum): Fixed bug due
+ * progmodes/cc-align.el (c-gnu-impose-minimum): Fix bug due
to the new placement of cpp-macro and comment-intro in the
- syntactic context, as pointed out by Kevin Ryde. Changed the
+ syntactic context, as pointed out by Kevin Ryde. Change the
method that decides whether point is inside a top-level
construct to one that doesn't depend on the set of syntactic
elements so much.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-cmds.el (c-mask-comment): Fixed a bug that
+ * progmodes/cc-cmds.el (c-mask-comment): Fix a bug that
sometimes caused code after a closed block comment to be taken
into account when the fill prefix is calculated.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-align.el (c-lineup-arglist, c-lineup-argcont,
- c-lineup-math, c-lineup-cascaded-calls, c-lineup-gcc-asm-reg):
+ * progmodes/cc-align.el (c-lineup-arglist, c-lineup-argcont)
+ (c-lineup-math, c-lineup-cascaded-calls, c-lineup-gcc-asm-reg):
Fixes to cope correctly with nested arglists for the lineups
that can be used with arglist-cont-nonempty.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-engine.el (c-add-stmt-syntax,
- c-guess-basic-syntax): Changed the anchor position of
+ * progmodes/cc-engine.el (c-add-stmt-syntax, c-guess-basic-syntax):
+ Change the anchor position of
arglist-cont-nonempty and arglist-close so that a relative
- indentation like + can be used with consistent results. Prior
- to this, the indentation engine more or less assumed that
- arglist-cont-nonempty always used `c-lineup-arglist'. Those
- two syntax symbols also get the opening paren as an extra
+ indentation like + can be used with consistent results.
+ Prior to this, the indentation engine more or less assumed that
+ arglist-cont-nonempty always used `c-lineup-arglist'.
+ Those two syntax symbols also get the opening paren as an extra
position, to make it possible for `c-lineup-arglist' to
continue to do a proper job.
- * progmodes/cc-engine.el (c-get-syntactic-indentation): A
- vector with an absolute indentation column now only overrides
+ * progmodes/cc-engine.el (c-get-syntactic-indentation):
+ A vector with an absolute indentation column now only overrides
the indentation for surrounding structures, i.e. those whose
syntactic elements are earlier in the `c-syntactic-context'
list, but not nested ones. This so that
nested things, e.g. the arglist-close of a nested argument
list. This change means that the order in
`c-syntactic-context' has become more essential.
-
(c-guess-basic-syntax): Changes to make the nesting order of the
returned syntax list correct.
* progmodes/cc-align.el, progmodes/cc-defs.el,
progmodes/cc-engine.el, progmodes/cc-vars.el
- (c-guess-basic-syntax, c-calc-offset,
- c-get-syntactic-indentation, c-syntactic-context): Extended
- the representation of the syntactic context: Previously it was
+ (c-guess-basic-syntax, c-calc-offset)
+ (c-get-syntactic-indentation, c-syntactic-context):
+ Extend the representation of the syntactic context: Previously it was
a list containing cons cells of the found syntactic symbols
and their relpos values. Now each element is instead a list
containing the syntactic symbol in the first element and the
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-styles.el (c-set-style, c-set-style-1): Added
- another state for the `dont-override' flag where it only keeps
+ * progmodes/cc-styles.el (c-set-style, c-set-style-1):
+ Add another state for the `dont-override' flag where it only keeps
globally set variables.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-vars.el, progmodes/cc-fonts.el,
- progmodes/cc-langs.el, progmodes/cc-mode.el: Added font lock
- support.
+ progmodes/cc-langs.el, progmodes/cc-mode.el: Add font lock support.
* progmodes/cc-engine.el (c-beginning-of-syntax): New function
- to be used for font-lock-beginning-of-syntax-function. It
- uses the state cache to quickly find a good position.
+ to be used for font-lock-beginning-of-syntax-function.
+ It uses the state cache to quickly find a good position.
* progmodes/cc-defs.el (c-major-mode-is): Allow a list of
modes. Made it a macro ensure that it's optimized to either
eq or memq for constant arguments.
- * progmodes/cc-mode.el (c-common-init): Did away with the
+ * progmodes/cc-mode.el (c-common-init): Do away with the
hardcoded setting of `comment-column'; it's a user variable
that we have no business meddling with. Since the default
value for it is 32 in all supported (X)Emacs versions, it's
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-engine.el (c-add-stmt-syntax): Fixed some cases
+ * progmodes/cc-engine.el (c-add-stmt-syntax): Fix some cases
of wrong anchoring, e.g. for else-if compounds.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-engine.el (c-guess-basic-syntax): Fixed anchor
+ * progmodes/cc-engine.el (c-guess-basic-syntax): Fix anchor
position for defun-open in K&R style functions.
- * progmodes/cc-engine.el (c-in-knr-argdecl): Don't trip up on
- macros.
+ * progmodes/cc-engine.el (c-in-knr-argdecl): Don't trip up on macros.
(c-search-decl-header-end): Handle C++ template arguments more
correctly.
- (c-beginning-of-decl-1): Fix when the declaration is first in a
- macro.
+ (c-beginning-of-decl-1): Fix when the declaration is first in a macro.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-langs.el (c-make-keywords-re): Fixed the
- keyword adornment so that it works when a keyword ends with
- "_".
+ * progmodes/cc-langs.el (c-make-keywords-re): Fix the
+ keyword adornment so that it works when a keyword ends with "_".
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
* progmodes/cc-cmds.el (c-mask-comment): More fixes when used
from `c-do-auto-fill' and point is at or near the limit of the
- comment. Fixed bug when the prefix from `c-guess-fill-prefix'
+ comment. Fix bug when the prefix from `c-guess-fill-prefix'
is longer than the text on the first line of the comment when
it's masked.
2003-07-03 Martin Stjernholm <bug-cc-mode@gnu.org>
- * progmodes/cc-cmds.el (c-mask-comment): Fixed bug where point
+ * progmodes/cc-cmds.el (c-mask-comment): Fix bug where point
was moved to the following line when it was at the first line
of a block comment where comment-start-skip matched to eol.
* menu-bar.el (menu-bar-options-menu): Move mouse-set-fonts item here.
- * international/mule-cmds.el (mule-menu-keymap): Delete
- mouse-set-fonts item here.
+ * international/mule-cmds.el (mule-menu-keymap):
+ Delete mouse-set-fonts item here.
2003-06-29 Nick Roberts <nick@nick.uklinux.net>
2003-06-27 Kai Gro\e,A_\e(Bjohann <kai.grossjohann@gmx.net>
- * international/mule-cmds.el (menu-bar-options-menu): Move
- `mouse-set-fonts' here from Options/Mule submenu.
+ * international/mule-cmds.el (menu-bar-options-menu):
+ Move `mouse-set-fonts' here from Options/Mule submenu.
2003-06-26 Stephen Eglen <stephen@gnu.org>
- * iswitchb.el (iswitchb-read-buffer): Remove redudant variable
+ * iswitchb.el (iswitchb-read-buffer): Remove redundant variable
iswitchb-prepost-hooks.
(iswitchb-xemacs): Delete variable and use (featurep 'xemacs)
and fboundp instead.
2003-06-20 Masatake YAMATO <jet@gyve.org>
- * progmodes/asm-mode.el (asm-font-lock-keywords): Support
- labels starting with "." and directives starting with ".".
+ * progmodes/asm-mode.el (asm-font-lock-keywords):
+ Support labels starting with "." and directives starting with ".".
2003-06-22 Andreas Schwab <schwab@suse.de>
- * emacs-lisp/easy-mmode.el (easy-mmode-define-navigation): Avoid
- variable as format argument for error. Don't call symbol-name on
- string.
+ * emacs-lisp/easy-mmode.el (easy-mmode-define-navigation):
+ Avoid variable as format argument for error.
+ Don't call symbol-name on string.
* eshell/esh-opt.el (eshell-do-opt): Avoid variable as format
argument for error.
(diary, view-diary-entries, show-all-diary-entries)
(mark-diary-entries): Use it.
(view-other-diary-entries): Doc fix. Use `prefix-numeric-value'.
- (diary-syntax-table, diary-attrtype-convert, diary-mail-days): Doc
- fix.
+ (diary-syntax-table, diary-attrtype-convert, diary-mail-days): Doc fix.
(diary-modified, d-file): No need to defvar (for compiler).
(list-diary-entries): No need for `let*' so use `let'.
(simple-diary-display): Use `diary-file' directly rather than
`mode-line-format' already buffer-local.
(diary-mail-addr): Set to the empty string (rather than nil) if
undefined, as per `user-mail-address'.
- (diary-mail-entries): Doc fix. Error if `diary-mail-address'
- unset.
+ (diary-mail-entries): Doc fix. Error if `diary-mail-address' unset.
(mark-sexp-diary-entries): Don't regexp-quote sexp-mark twice.
Remove an un-needed `if'.
(list-sexp-diary-entries): Remove local vars mark and s-entry, and