branch: externals/ada-mode commit 62808b44d4ff07e37beb5103994982de2ed1f415 Author: Stephen Leake <stephen_le...@stephe-leake.org> Commit: Stephen Leake <stephen_le...@stephe-leake.org>
* NEWS: Release 7.2.0 * README: Bump version. * ada-mode.el: * ada-mode.texi: * ada-gnat-xref.el (ada-gnat-xref-refs): Actually fix xref change. * gpr-query.el (gpr-query-tree-refs): --- NEWS | 10 ++++++++++ README | 2 +- ada-gnat-xref.el | 14 +++++++++----- ada-mode.el | 2 +- ada-mode.texi | 4 ++-- gpr-query.el | 14 +++++++++----- 6 files changed, 32 insertions(+), 14 deletions(-) diff --git a/NEWS b/NEWS index 94bb7a3..fe3e518 100644 --- a/NEWS +++ b/NEWS @@ -6,6 +6,16 @@ Please send ada-mode bug reports to bug-gnu-em...@gnu.org, with 'ada-mode' in the subject. If possible, use M-x report-emacs-bug. +* Ada Mode 7.2.0 +21 Nov 2021 + +** Correct last fix (sigh). + +* Ada Mode 7.1.9 +21 Nov 2021 + +** Adapt to change in xref.el xref-file-location. + * Ada Mode 7.1.8 09 Aug 2021 diff --git a/README b/README index 1dfc093..00bd1a9 100644 --- a/README +++ b/README @@ -1,4 +1,4 @@ -Emacs Ada mode version 7.1.9 +Emacs Ada mode version 7.2.0 Ada mode provides auto-casing, fontification, navigation, and indentation for Ada source code files. diff --git a/ada-gnat-xref.el b/ada-gnat-xref.el index 2b16cff..a48338f 100644 --- a/ada-gnat-xref.el +++ b/ada-gnat-xref.el @@ -141,13 +141,17 @@ elements of the result may be nil." (defun ada-gnat-xref-refs (project item all) ;; WORKAROUND: xref 1.3.2 xref-location changed from defclass to cl-defstruct - (with-suppressed-warnings (nil) ;; "unknown slot" + (with-no-warnings ;; "unknown slot" (let ((summary (if (functionp 'xref-item-summary) (xref-item-summary item) (oref item :summary))) (location (if (functionp 'xref-item-location) (xref-item-location item) (oref item :location)))) - (let ((file (if (functionp 'xref-location-file) (xref-location-file location) (oref location :file))) - (line (if (functionp 'xref-location-line) (xref-location-line location) (oref location :line))) - (column (if (functionp 'xref-location-column) - (xref-location-column location) + (let ((file (if (functionp 'xref-file-location-file) + (xref-file-location-file location) + (oref location :file))) + (line (if (functionp 'xref-file-location-line) + (xref-file-location-line location) + (oref location :line))) + (column (if (functionp 'xref-file-location-column) + (xref-file-location-column location) (oref location :column)))) (let* ((wisi-xref-full-path t) (args (cons "-r" (ada-gnat-xref-common-args project summary file line column))) diff --git a/ada-mode.el b/ada-mode.el index aade98d..a65c7b4 100644 --- a/ada-mode.el +++ b/ada-mode.el @@ -6,7 +6,7 @@ ;; Maintainer: Stephen Leake <stephen_le...@stephe-leake.org> ;; Keywords: languages ;; ada -;; Version: 7.1.9 +;; Version: 7.2.0 ;; package-requires: ((uniquify-files "1.0.1") (wisi "3.1.5") (emacs "25.3")) ;; url: http://www.nongnu.org/ada-mode/ ;; diff --git a/ada-mode.texi b/ada-mode.texi index 94b1e17..a5a1dbc 100644 --- a/ada-mode.texi +++ b/ada-mode.texi @@ -25,7 +25,7 @@ developing GNU and promoting software freedom.'' @titlepage @sp 10 -@title Ada Mode Version 7.1.9 +@title Ada Mode Version 7.2.0 @page @vskip 0pt plus 1filll @insertcopying @@ -37,7 +37,7 @@ developing GNU and promoting software freedom.'' @node Top, Overview, (dir), (dir) @top Top -Ada Mode Version 7.1.9 +Ada Mode Version 7.2.0 @end ifnottex @menu diff --git a/gpr-query.el b/gpr-query.el index 246cd14..da3a8e4 100644 --- a/gpr-query.el +++ b/gpr-query.el @@ -721,14 +721,18 @@ FILE is from gpr-query." (defun gpr-query-tree-refs (project item op) "Run gpr_query tree command OP on ITEM (an xref-item), return list of xref-items." ;; WORKAROUND: xref 1.3.2 xref-location changed from defclass to cl-defstruct - (with-suppressed-warnings (nil) ;; "unknown slot" + (with-no-warnings ;; "unknown slot" (let ((summary (if (functionp 'xref-item-summary) (xref-item-summary item) (oref item :summary))) (location (if (functionp 'xref-item-location) (xref-item-location item) (oref item :location))) (eieio-skip-typecheck t)) ;; 'location' may have line, column nil - (let ((file (if (functionp 'xref-location-file) (xref-location-file location) (oref location :file))) - (line (if (functionp 'xref-location-line) (xref-location-line location) (oref location :line))) - (column (if (functionp 'xref-location-column) - (xref-location-column location) + (let ((file (if (functionp 'xref-file-location-file) + (xref-file-location-file location) + (oref location :file))) + (line (if (functionp 'xref-file-location-line) + (xref-file-location-line location) + (oref location :line))) + (column (if (functionp 'xref-file-location-column) + (xref-file-location-column location) (oref location :column)))) (when (eq ?\" (aref summary 0))