1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-12-16 09:50:25 +00:00
Commit Graph

57 Commits

Author SHA1 Message Date
Richard M. Stallman
2389f14324 (ada-mode): Don't use advice. Instead, set which-func-functions. 2003-09-30 12:54:32 +00:00
Miles Bader
ab5796a9f9 Add arch taglines 2003-09-01 15:45:59 +00:00
Stefan Monnier
f7a2f2c654 (ada-in-comment-p, ada-in-string-p)
(ada-in-string-or-comment-p): Use line-beginning-position.
2003-05-13 20:48:15 +00:00
Juanma Barranquero
6f9a2614e7 (ada-xemacs): Variable removed, since it's better to use (featurep 'xemacs).
Removed warnings generated with Emacs 21.3.x (mostly by adding needed `require'
statements).
2003-05-04 19:55:38 +00:00
Juanma Barranquero
f7a8090935 (ada-search-directories): Take into account ADA_INCLUDE_PATH for better
compatibility with GNAT.
(ada-contextual-menu): Menu defined through `easy-menu-define' instead.  Various
adjustments to the indentation engine (handling of subtypes, begin blocks,
etc.).
(ada-create-menu): Major rewrite of the handling of menus to use
`easy-menu-define' for cleaner code and better compatibility with XEmacs.  All
menus that were previously in ada-xref.el and ada-prj.el are now defined in this
package, which makes it easier to edit menus.
(ada-narrow-to-defun): Add support for `narrow-to-region'.  No longer
explicitely load ada-xref.el and ada-prj.el.  Use autoload statements instead.
2003-04-29 23:35:40 +00:00
Juanma Barranquero
a1506d2977 Trailing whitepace deleted. 2003-02-04 13:24:35 +00:00
Stefan Monnier
80d50f8814 * progmodes/ada-mode.el: Update copyright notice.
Synchronize with GNAT release 3.15a1.
Do not attempt to load ada-support, which is only for compatibility
with older Emacs versions, and is not needed for Emacs 21.
(ada-continuation-indent): New variable.
New contextual menu: "List local reference", faster than "List References".
(ada-mode): New alignment rules provided by S. Leake.
(ada-mode): Add support for which-function-mode.
Fix various calls to count-lines, that didn't work correctly when the
buffer was narrowed.
(ada-get-current-indent): Fix indentation of named parameter lists and
nested boolean expressions.
(ada-indent-on-previous-lines): Fix indentation of labels.
(ada-search-prev-end-stmt): Fix searching of the previous end-statement,
specially with regards to nested subprograms.
(comment-region advice): Initially disabled, for better compatibility with
other modes.
(ada-fill-comment-paragraph): Fixed (no longer worked with Emacs 21).

* progmodes/ada-xref.el: Update copyright notice.
(ada-xref-create-ali): The default is now not to create automatically the
ALI files by compiling the unit, since this isn't always reliable and
requires an up-to-date project file.
(ada-prj-default-comp-cmd): No longer use gcc directly to compile
a file, but use gnatmake instead, since this gives access to the GNAT
project files.
(ada-xref-search-with-egrep): New variable, suggested by P. Waroquiers.
(ada-load-project-hook): New variable, for support of GNAT project files.
(ada-update-project-menu): Fix the detection of the project file name.
(ada-add-keymap): Change key binding for ada-find-file, that conflicted
with another binding in ada-mode.el.
(ada-add-menu): New menu "List Local References", to list the reference
to the entity only in the current file, instead of looking in the whole
project.  Much faster.
(ada-find-references): New parameters arg and local-only.
(ada-find-any-references): New parameters local-only and append.
(ada-goto-declaration): Fix handling of predefined entities in xref.
(ada-get-all-references): Updated to the new xref format in GNAT 3.15,
still compatible with GNAT 3.14 of course.  Fix various calls to
count-lines, that didn't work correctly when the buffer was narrowed.
2002-06-20 17:40:38 +00:00
Richard M. Stallman
7aeff5ab52 Comment change. 2002-04-28 21:14:17 +00:00
Stefan Monnier
4607c7f433 (ada-case-exception-file, ada-indent-handle-comment-special): New variables.
(ada-case-exception-substring): New variable.  Casing exceptions can
now also be defined for substrings, in addition to full identifier
names.  This provides more flexibility.
(ada-align-list): New function, provide support for align.el in ada-mode.
(ada-procedure-start-regexp): Add support for operators and generic formal
subprograms and packages.
(ada-imenu-comment-re): New variable.
(ada-imenu-generic-expression): Add support for protected types.
(ada-mode): Set comment-start only after running ada-mode-hook, so that the
user can change ada-comment-start in the hook.
Add support for ispell in comments.  Add support for align.el.
(ada-save-exception-file, ada-create-case-exception-substring)
(ada-adjust-case-substring): New functions.
(ada-get-current-indent): Properly handles keywords with uppercases.
(ada-goto-matching-end): Rewritten, fixes problems in the handling of
nested blocks.
(ada-untab-hard): Do not touch the contents of comments and strings.
2002-04-09 18:50:17 +00:00
Pavel Janík
c3b7828887 (ada-initialize-properties, ada-mode): Do not use make-local-hook. 2002-01-08 21:43:42 +00:00
Pavel Janík
f0529b5b1a Doc fix. 2001-12-20 19:01:00 +00:00
Andreas Schwab
1997815f8b (ada-add-extensions): Quote regexp special
characters and append anchor to pattern added to auto-mode-alist.
2001-11-15 15:50:10 +00:00
Richard M. Stallman
10bcf543b7 (ada-fill-comment-prefix): Doc fix. 2001-11-14 03:49:57 +00:00
Stefan Monnier
5ebcaf3609 (ada-fill-comment-prefix): GNAT wants 2 spaces. 2001-11-13 14:25:57 +00:00
Stefan Monnier
5dab0769af (ada-mode): Avoid unneeded version checks.
Don't change compile-auto-highlight globally.
Don't bother with `font-lock-defaults' property since XEmacs
also understands the `font-lock-defaults' variable.
Use make-local-variable rather than make-variable-buffer-local.
Don't `defconst' comment-indent-function: keep the default.
Call easy-menu-add unconditionally.
(ada-create-keymap): Use [(shift tab)] so it works on both Emacsen.
(ada-create-menu): Use :included for Emacs as well.
2001-07-16 15:12:19 +00:00
Pavel Janík
3afbc435ac Some fixes to follow coding conventions. 2001-07-16 07:46:48 +00:00
Gerd Moellmann
2be7dabcae Fix license commentary. 2001-07-13 12:59:13 +00:00
Eli Zaretskii
874d799506 Say that the file _is_ part of Emacs. 2001-07-11 10:21:04 +00:00
Dave Love
7c5fd35547 (ada-popup-key): Fix :type. 2001-02-07 23:25:59 +00:00
Dave Love
50a8310e77 (ada-popup-key): Fix last change. 2001-01-12 12:40:28 +00:00
Dave Love
2bef3a39ac (ada-popup-key): Fix :type. 2001-01-09 16:34:51 +00:00
Sam Steingold
eaae8106d7 * simple.el (delete-trailing-whitespace): New interactive function.
* progmodes/ada-mode.el (ada-mode): Use it instead of
`ada-remove-trailing-spaces'
(ada-remove-trailing-spaces): Removed.
* textmodes/two-column.el (2C-merge): Recommend it in the doc.
* textmodes/picture.el (picture-mode-exit): Call it instead of
`picture-clean'.
(picture-clean): Removed.
2000-11-22 20:59:39 +00:00
Stefan Monnier
36144b26b5 (ada-mode): set '' -> setq'. 2000-11-21 22:41:20 +00:00
Dave Love
88127f30ed (ada-mode-menu): Add name to menu map. 2000-10-08 17:47:03 +00:00
Gerd Moellmann
4cc7e49821 Got rid of all byte-compiler warnings on Emacs Load
ada-xref.el before ada-prj.el, so that the Project menu is created
when ada-prj tries to add to it.
(ada-activate-keys-for-case): Suppress the characters that are not
part of the Ada syntax. Better compatibility with else-mode
(ada-adjust-case-interactive): When auto-casing is not active,
correctly insert newlines (used to insert only ^M).  Prevent the
syntax table from being changed in case of an error
(or '_' becomes part of a word and some commands are confused).
Do nothing if ada-auto-case is nil.
(ada-after-keyword-p): Ignore keywords that are also attributes
(ada-batch-reformat): Update usage comment
(ada-call-from-contextual-menu): New function
(ada-case-read-exceptions): Reinitialize the casing exception list
first to nil first, so that the casing exception file can be
shared.
(ada-check-defun-name): Handles "configure" keyword for gnatdist
files.
(ada-compile-goto-error): Fix regexp used to detect a file:line
anywhere in the error message
(ada-contextual-menu-last-point): New variable
(ada-create-keymap): If the variable delete-key-deletes-forward is
t on XEmacs, it means that DEL should delete one character
forward.
(ada-create-menu): Use :included instead of :visible for XEmacs.
New submenu "Options".
(ada-end-stmt-re): Correctly indent "select ... then abort"
statements.
(ada-fill-comment-paragraph): Correctly delete all leading '--'
even if they don't match ada-fill-comment-prefix Fix handling of
paragraphs on the first or last line of a file.
(ada-format-paramlist): Fix handling of default parameter values.
(ada-get-body-name): New function.
(ada-get-current-indent): Optimized by searchling directly for an
existing generic part or a statement outside of it.  Handle
ada-indent-align-comments when indenting comments Replaced some
regexps by testing directly the next character. This results in a
huge speedup on some files.  New indentation scheme for renames
statements.  Stop looking for the 'while' or 'for' associated with
a 'loop' at the first semicolon encountered.  A "return" can also
match an anonymous access subprogram declaration.
(ada-get-indent-noindent): Ignore strings and comments when
looking for the keywords "record" and "private".
(ada-goto-matching-decl-start): When matching "if", make sure we
are not in fact seeing "end if".  Ignore "when" statements except
when initial keyword was "begin".  Fix handling of nested
procedures.  Add a recursive call to this function to skip over
other 'end' statmts.  Fix indentation for "when .. => begin"
(ada-in-open-paren-p): Fix indentation for complex boolean
expressions, where 'and then', 'or else' and parenthesis
statements are mixed up.
(ada-in-paramlist-p): Skip comments while searching for the
beginning Fix handling of operator declarations.
(ada-indent-align-comments): New variable
(ada-indent-current): Change the syntax table only in the
protected section, so that we are sure it is restored correctly.
(ada-indent-on-previous-lines): Use ada-use-indent and
ada-with-indent Correctly indent "select ... then"
(ada-indent-region): Slight speedup.
(ada-indent-renames): New variable.
(ada-last-which-function-subprog, ada-last-which-function-line):
New variables
(ada-looking-at-semi-private): Correctly indent the 'private'
keyword when it is the first word in a package declaration.
(ada-loose-case-word): Stop searching if at the end of the buffer.
(ada-loose-case-word, ada-capitalize-word): Recase the whole word
even if point is not initially at the end of the word.
(ada-matching-decl-start-re): Add "when".
(ada-mode): Add support for abbrev-mode, outline-mode and
which-func-mode Override the old find-file.el entry in
ff-special-constructs since it is using the obsolete
ada-spec-suffix variable
(ada-no-auto-case): New function
(ada-scan-paramlist): When parsing the argument type, accept
spaces (as in "X 'Class", generated by Rational Rose).
(ada-other-file-name): No longer loads the other file.
(ada-popup-menu): Save and restore the current buffer and cursor
position before and after displaying the menu.
(ada-search-ignore-complex-boolean): New function.
(ada-uncomment-region): Emacs21 already knows how to delete
comments not starting in the first column.
(ada-use-indent): New variable
(ada-which-function): New function.
(ada-with-indent): New variable
(ada-xemacs): evaluate it at compile time too, so that ada-mode.el
can be batch-compiled from the command line.
2000-07-24 11:14:26 +00:00
Stefan Monnier
db72f2a606 (ada-mode, ada-create-case-exception): Don't quote lambdas. 2000-05-19 21:40:45 +00:00
Gerd Moellmann
655880d250 Changed format of years in copyright notice. 1999-10-28 11:00:34 +00:00
Gerd Moellmann
7749c1a8cd (ada-get-indent-*, ada-indent-current, ada-goto-*,
ada-indent-newline-indent): Rewritten to support the new indentation
scheme
(ada-case-read-exceptions, ada-create-case-exceptions):
New functions
(ada-fill-comment-paragraph): Add support for the
justification parameter
(ada-make-body, ada-gen-treat-proc,
ada-make-subprogram-body): Rewritten to benefit from the gnatstub
external program
1999-10-07 14:33:10 +00:00
Richard M. Stallman
5e8b779fcb (ada-tmp-directory): Use temporary-file-directory. 1999-08-28 18:25:40 +00:00
Dave Love
b073b657d4 (ada-outline-level): Bind buffer-invisibility-spec. 1999-03-06 19:06:40 +00:00
Richard M. Stallman
8e70c858a7 Record new maintainer. 1999-02-16 03:07:34 +00:00
Richard M. Stallman
f9e6a7e8f5 Fix author's email address. 1998-09-28 09:20:40 +00:00
Karl Heuer
452b228575 (ada-search-ignore-string-comment):
In "found in comment" case, don't beginning-of-line after forward-line.
1998-09-04 19:58:39 +00:00
Simon Marshall
883212ce69 Changed font-lock-reference-face to font-lock-constant-face. 1998-02-20 14:58:27 +00:00
Dave Love
c0b08eb017 Use imenu-case-fold-search. 1997-12-12 17:10:08 +00:00
Richard M. Stallman
c69dd504e5 Finish installing previous change. 1997-06-02 19:58:49 +00:00
Richard M. Stallman
52748d9537 Customize.
(ada-mode): Set up support for find-file.el.
(ada-other-file-alist): New variable moved from find-file.el.
(ada-search-directories): Likewise.
1997-06-02 06:06:03 +00:00
Richard M. Stallman
d03b8a2d00 Comment changes. 1997-05-28 03:50:36 +00:00
Richard M. Stallman
c1bb59cab2 Comment change. 1997-05-23 04:56:15 +00:00
Richard M. Stallman
cadd365812 (ada-krunch-args): Use gnatkr instead of gnatk8.
(ada-make-filename-from-adaname): Ditto.
(ada-adjust-case-region): Use format functionality of message.
(ada-indent-region): Ditto.
(ada-check-matching-start): Ditto.
(ada-check-defun-name): Ditto.

(ada-font-lock-keywords): Default to subdued.  Doc fix.
(ada-font-lock-syntactic-keywords): New variable.
(ada-mode): Use it to set font-lock-defaults.

(ada-font-lock-keywords-2): Single "raise" will be
highlighted. "in out" parameters get type face (depends on order
in regexp).

(ada-mode): Remove explicit setting of user option
`blink-matching-paren', font-lock treats `.' as word char.
(ada-in-string-or-comment-p): Call `parse-partial-sexp' only once.
(ada-untabify-buffer): Force returning `nil'.
(ada-font-lock-keywords-1): Move "task" before "task (body|type)" to
correct highlighting (regexp depends on order).

(ada-in-char-const-p): Renamed from `ada-after-char-p'.
Also test following character.
(ada-adjust-case): Use better function `ada-in-char-const-p'
(ada-in-string-or-comment-p): Test for being in a char constant.
(ada-clean-buffer-before-saving): Changed default to t.
(ada-mode): Set `font-lock-defaults' for Emacs only, use properties
for XEmacs.

(ada-indent-newline-indent): Simplified by just calling
`ada-indent-current'.

(ada-end-stmt-re): Added word delimiters in regexp.
Removed `interactive' statements which were needed only for debugging.

Put format commands back in for emacs 19.30/19.29 compatibility.

(ada-get-indent-label): A named block can begin
without a declare part.
(ada-check-defun-name): First of all, check for correct name in a
named block without `declare' part.
(ada-goto-matching-start): Change regexp as there may be no
semicolon between `end' and keyword.
(ada-get-current-indent): Remove warning as `begin' can introduce
a block without a `declare'.
(ada-goto-matching-decl-start): When searching backward, skip
generic default proc/func ("is <>").

(ada-named-block-re): New regexp for the name of a named block or loop.
(ada-get-current-indent): Handle loop names at the stmt start.
(ada-get-indent-end): Handle loop names at the stmt start.
(ada-get-indent-noindent): Handle loop names at the stmt start.
(ada-get-indent-loop): Handle loop names at the stmt start.
(ada-search-prev-end-stmt): Generic instances are not `stmt-ends'.
(ada-goto-previous-word): Use new function `ada-goto-next-word'.
(ada-goto-next-word): Generalized old `ada-goto-previous-word' for
both directions.

(ada-indent-function): Removed unnecessary `package' case.
(ada-get-indent-case): Before testing for `=>', be sure there is an `is'.
(ada-search-prev-end-stmt): Test for `separate' keyword on the
same line, which is not an `end-stmt'.

(ada-font-lock-keywords-2):
Correct regexp for hilit of unfollowed `end'.
(ada-in-open-paren-p): Start parsing definitely outside of strings.
(ada-gnat-style): New function.

Doc fixes.
(ada-mode): Support new font-lock-mode.
(ada-format-paramlist): Changed all `accept' to `access'.
(ada-insert-paramlist): Changed all `accept' to `access'.
(ada-in-comment-p): Use standard emacs way `parse-partial-sexp'.
(ada-font-lock-keywords-1): Regexps in not byte-compiled code bahave
different than byte-compiled regexps.
Change order of some ored entries.
1997-05-22 01:58:55 +00:00
Karl Heuer
4dd3b39642 (ada-indent-region, ada-check-matching-start, ada-check-defun-name): Fix error
format string.
1996-01-29 23:09:15 +00:00
Karl Heuer
5fb0f713c5 (ada-adjust-case-region, ada-indent-region): Delete format call inside message. 1996-01-25 00:59:05 +00:00
Erik Naggum
b578f267af Update FSF's address. 1996-01-14 07:34:30 +00:00
Karl Heuer
3746aa5590 (ada-case-keyword, ada-auto-case, ada-krunch-args,
ada-call-pretty-printer): Doc fix.
1996-01-04 23:25:15 +00:00
Richard M. Stallman
be01074898 Comment change. 1995-10-30 17:35:01 +00:00
Richard M. Stallman
5e1cecee20 All doc strings changed to comply with standard Emacs conventions.
(ada-mode): Support new font-lock-mode.
(ada-format-paramlist): Changed all `accept' to `access'.
(ada-insert-paramlist): Changed all `accept' to `access'.
(ada-in-comment-p): Use standard Emacs way `parse-partial-sexp'.
(ada-font-lock-keywords-1): Change order of some alternatives.
1995-10-17 03:33:46 +00:00
Erik Naggum
dcf804a0a9 (ada-gen-treat-proc): Bind procname' and functype'. 1995-10-09 03:11:29 +00:00
Karl Heuer
74480345ab (ada-imenu-generic-expression): Var defined.
(ada-mode): Set imenu-generic-expression.
1995-07-28 00:18:42 +00:00
Richard M. Stallman
276c121047 (ada-ident-re): Doc fix.
(ada-end-stmt-re): Corrected serious pb of wrong parentheses.
(ada-subprog-start-re): Removed 'body' from the list.
(ada-format-paramlist): Simplified a regexp.
(ada-indent-current): On first line of the buffer, indent to column 0.
Don't reindent if new position is the same as the old one.  Thus, a
correcly indended line is not modified.
(ada-get-indent-subprog): Simplified a regexp.
(ada-goto-matching-decl-start): Distinguish between normal type
declaration and protected types, which are more like procedures.
(ada-remove-trailing-spaces): Use save-match-data, save-restriction
and widen when removing whitespace.
(ada-font-lock-keywords-1): Add 'pragma' as keyword.
(ada-font-lock-keywords-2): Allow *qualified* idents after 'end'.
1995-07-18 20:48:04 +00:00
Karl Heuer
30ffd6211a Remove version information. 1995-06-02 00:14:33 +00:00