[elpa] externals/org c0dde2c 1/2: oc-basic: Fix `org-cite-basic-goto'

2021-07-30 Thread ELPA Syncer
branch: externals/org
commit c0dde2c8003ef76f9f6589049529a84cccf4ea5c
Author: Nicolas Goaziou 
Commit: Nicolas Goaziou 

oc-basic: Fix `org-cite-basic-goto'

* lisp/oc-basic.el (org-cite-basic-goto): Set BibTeX dialect before
calling `bibtex-search-entry'.
---
 lisp/oc-basic.el | 15 +--
 1 file changed, 9 insertions(+), 6 deletions(-)

diff --git a/lisp/oc-basic.el b/lisp/oc-basic.el
index 4e9d2e5..a5b5588 100644
--- a/lisp/oc-basic.el
+++ b/lisp/oc-basic.el
@@ -654,12 +654,15 @@ present in the citation."
 (`(,f . ,_) f)
 (_  (user-error "Cannot find citation key: %S" key)
 (org-open-file file '(4))
-(if (not (equal "json" (file-name-extension file)))
-(bibtex-search-entry key)
-  (let ((regexp (rx "\"id\":" (0+ (any "[ \t]")) "\"" (literal key) "\"")))
-(goto-char (point-min))
-(re-search-forward regexp)
-(search-backward "{")
+(pcase (file-name-extension file)
+  ("json"
+   (let ((regexp (rx "\"id\":" (0+ (any "[ \t]")) "\"" (literal key) 
"\"")))
+ (goto-char (point-min))
+ (re-search-forward regexp)
+ (search-backward "{")))
+  (_
+   (bibtex-set-dialect)
+   (bibtex-search-entry key)
 
 
 ;;; "Insert" capability



[elpa] externals/org updated (c839849 -> 1857068)

2021-07-30 Thread ELPA Syncer
elpasync pushed a change to branch externals/org.

  from  c839849   footnote: Allow inserting footnotes at the end of table 
cells
   new  c0dde2c   oc-basic: Fix `org-cite-basic-goto'
   new  1857068   oc-basic: Improve  handling on citation keys


Summary of changes:
 lisp/oc-basic.el | 70 +---
 1 file changed, 42 insertions(+), 28 deletions(-)



[elpa] externals/org 1857068 2/2: oc-basic: Improve handling on citation keys

2021-07-30 Thread ELPA Syncer
branch: externals/org
commit 18570684ad13b004ee1c5013ee843fa53576008a
Author: Nicolas Goaziou 
Commit: Nicolas Goaziou 

oc-basic: Improve  handling on citation keys

* lisp/oc-basic.el (org-cite-basic--set-keymap): New function.
(org-cite-basic--make-repair-keymap): Remove function.
(org-cite-basic-activate): Use new function.
---
 lisp/oc-basic.el | 55 +--
 1 file changed, 33 insertions(+), 22 deletions(-)

diff --git a/lisp/oc-basic.el b/lisp/oc-basic.el
index a5b5588..c46e7a7 100644
--- a/lisp/oc-basic.el
+++ b/lisp/oc-basic.el
@@ -67,6 +67,8 @@
 (require 'bibtex)
 (require 'oc)
 
+(declare-function org-open-at-point "org" (&optional arg))
+
 (declare-function org-element-interpret-data "org-element" (data))
 (declare-function org-element-property "org-element" (property element))
 (declare-function org-element-type "org-element" (element))
@@ -399,21 +401,28 @@ Optional argument INFO is the export state, as a property 
list."
 (org-string-distance k key)))
   keys))
 
-(defun org-cite-basic--make-repair-keymap (beg end suggestions)
-  "Return keymap active on wrong citation keys.
-BEG and END are boundaries of the wrong citation.  SUGGESTIONS is a list of
-replacement keys, as strings."
-  (let ((km (make-sparse-keymap))
-(f (lambda ()
- (interactive)
- (setf (buffer-substring beg end)
-   (concat "@"
-   (if (= 1 (length suggestions))
-   (car suggestions)
- (completing-read "Substitute key: "
-  suggestions nil t)))
-(define-key km (kbd "") f)
-km))
+(defun org-cite-basic--set-keymap (beg end suggestions)
+  "Set keymap on citation key between BEG and END positions.
+
+When the key is know, SUGGESTIONS is nil.  Otherwise, it may be
+a list of replacement keys, as strings, which will be offered as
+substitutes for the unknown key.  Finally, it may be the symbol
+`all'."
+  (let ((km (make-sparse-keymap)))
+(define-key km (kbd "")
+  (pcase suggestions
+('nil #'org-open-at-point)
+('all #'org-cite-insert)
+(_
+ (lambda ()
+   (interactive)
+   (setf (buffer-substring beg end)
+ (concat "@"
+ (if (= 1 (length suggestions))
+ (car suggestions)
+   (completing-read "Did you mean: "
+suggestions nil t
+(put-text-property beg end 'keymap km)))
 
 (defun org-cite-basic-activate (citation)
   "Set various text properties on CITATION object.
@@ -438,24 +447,26 @@ them with a mouse click."
 (if (member key keys)
 ;; Activate a correct key.  Face is `org-cite-key' and
 ;; `help-echo' displays bibliography entry, for reference.
+;;  calls `org-open-at-point'.
 (let* ((entry (org-cite-basic--get-entry key))
(bibliography-entry
 (org-element-interpret-data
  (org-cite-basic--print-entry entry "plain"
   (add-face-text-property beg end 'org-cite-key)
-  (put-text-property beg end 'help-echo bibliography-entry))
+  (put-text-property beg end 'help-echo bibliography-entry)
+  (org-cite-basic--set-keymap beg end nil))
   ;; Activate a wrong key.  Face is `error', `help-echo'
-  ;; displays possible suggestions, and  provides
-  ;; completion to fix the key.
+  ;; displays possible suggestions.
   (add-face-text-property beg end 'error)
   (let ((close-keys (org-cite-basic--close-keys key keys)))
 (when close-keys
   (put-text-property beg end 'help-echo
  (concat "Suggestions (mouse-1 to substitute): 
"
- (mapconcat #'identity close-keys " 
")))
-  (put-text-property beg end 'keymap
- (org-cite-basic--make-repair-keymap
-  beg end close-keys)
+ (mapconcat #'identity close-keys " 
"
+;; When the are close know keys,  provides
+;; completion to fix the current one.  Otherwise, call
+;; `org-cite-insert'.
+(org-cite-basic--set-keymap beg end (or close-keys 'all
 
 
 ;;; "Export" capability



[elpa] externals/corfu fbcd636: Fix popup position if line is wrapped with truncate-lines=nil

2021-07-30 Thread ELPA Syncer
branch: externals/corfu
commit fbcd636f76de102068865e303e8c795d218af3a5
Author: Daniel Mendler 
Commit: Daniel Mendler 

Fix popup position if line is wrapped with truncate-lines=nil
---
 corfu.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/corfu.el b/corfu.el
index 7d350a4..3529608 100644
--- a/corfu.el
+++ b/corfu.el
@@ -381,7 +381,7 @@ completion began less than that number of seconds ago."
  (x (or (car (posn-x-y (posn-at-point pos))) 0))
  (y (save-excursion
   (goto-char pos)
-  (beginning-of-line)
+  (beginning-of-visual-line)
   (or (cdr (posn-x-y (posn-at-point))) 0
 (corfu--make-frame
  (- x mw) y



[elpa] externals/tramp 3e19596: Tramp ELPA version 2.5.1.1 released

2021-07-30 Thread ELPA Syncer
branch: externals/tramp
commit 3e195960bed24ff5910752f839bcd56862292d67
Author: Michael Albinus 
Commit: Michael Albinus 

Tramp ELPA version 2.5.1.1 released
---
 test/tramp-tests.el | 215 +++-
 texi/tramp.texi |  38 --
 texi/trampver.texi  |   2 +-
 tramp-adb.el|  39 +++---
 tramp-archive.el|   4 +
 tramp-cache.el  |   6 +-
 tramp-compat.el |  24 ++
 tramp-crypt.el  |  23 ++
 tramp-fuse.el   |  17 -
 tramp-gvfs.el   |  24 --
 tramp-rclone.el |   8 ++
 tramp-sh.el | 159 ++
 tramp-smb.el|  34 +++--
 tramp-sshfs.el  |  44 ---
 tramp-sudoedit.el   |  31 ++--
 tramp.el| 187 +++--
 trampver.el |   6 +-
 17 files changed, 683 insertions(+), 178 deletions(-)

diff --git a/test/tramp-tests.el b/test/tramp-tests.el
index 68caadb..98493bf 100644
--- a/test/tramp-tests.el
+++ b/test/tramp-tests.el
@@ -33,7 +33,7 @@
 ;; remote host, set this environment variable to "/dev/null" or
 ;; whatever is appropriate on your system.
 
-;; For slow remote connections, `tramp-test43-asynchronous-requests'
+;; For slow remote connections, `tramp-test44-asynchronous-requests'
 ;; might be too heavy.  Setting $REMOTE_PARALLEL_PROCESSES to a proper
 ;; value less than 10 could help.
 
@@ -63,6 +63,8 @@
 (declare-function tramp-smb-get-localname "tramp-smb")
 (defvar ange-ftp-make-backup-files)
 (defvar auto-save-file-name-transforms)
+(defvar lock-file-name-transforms)
+(defvar remote-file-name-inhibit-locks)
 (defvar tramp-connection-properties)
 (defvar tramp-copy-size-limit)
 (defvar tramp-display-escape-sequence-regexp)
@@ -122,6 +124,7 @@
 (setq auth-source-save-behavior nil
   password-cache-expiry nil
   remote-file-name-inhibit-cache nil
+  tramp-allow-unsafe-temporary-files t
   tramp-cache-read-persistent-data t ;; For auth-sources.
   tramp-copy-size-limit nil
   tramp-persistency-file-name nil
@@ -2463,6 +2466,9 @@ This checks also `file-name-as-directory', 
`file-name-directory',
  "^\\'")
tramp--test-messages
 
+   ;; We do not test lockname here.  See
+   ;; `tramp-test39-make-lock-file-name'.
+
;; Do not overwrite if excluded.
(cl-letf (((symbol-function #'y-or-n-p) #'tramp--test-always)
  ;; Ange-FTP.
@@ -2833,8 +2839,7 @@ This tests also `file-directory-p' and 
`file-accessible-directory-p'."
   (delete-directory tmp-name1 nil 'trash)
   ;; tramp-rclone.el and tramp-sshfs.el call the local
   ;; `delete-directory'.  This raises another error.
-  :type (if (or (tramp--test-rclone-p) (tramp--test-sshfs-p))
-'error 'file-error))
+  :type (if (tramp--test-fuse-p) 'error 'file-error))
  (delete-directory tmp-name1 'recursive 'trash)
  (should-not (file-directory-p tmp-name1))
  (should
@@ -4091,7 +4096,7 @@ This tests also `make-symbolic-link', `file-truename' and 
`add-name-to-file'."
(write-region "foo" nil tmp-name1)
(should (file-exists-p tmp-name1))
(should (file-selinux-context tmp-name1))
-   (copy-file tmp-name1 tmp-name2)
+   (copy-file tmp-name1 tmp-name2 nil nil nil 'preserve-permissions)
(should (file-selinux-context tmp-name2))
(should
 (equal
@@ -5480,7 +5485,8 @@ Use direct async.")
 
   (dolist (quoted (if (tramp--test-expensive-test) '(nil t) '(nil)))
 (let ((tmp-name1 (tramp--test-make-temp-name nil quoted))
- (tmp-name2 (tramp--test-make-temp-name nil quoted)))
+ (tmp-name2 (tramp--test-make-temp-name nil quoted))
+ tramp-allow-unsafe-temporary-files)
 
   (unwind-protect
  (progn
@@ -5568,8 +5574,7 @@ Use direct async.")
 
;; Create temporary file.  This shall check for sensible
;; files, owned by root.
-   (let ((tramp-auto-save-directory temporary-file-directory)
- tramp-allow-unsafe-temporary-files)
+   (let ((tramp-auto-save-directory temporary-file-directory))
  (write-region "foo" nil tmp-name1)
  (when (zerop (or (tramp-compat-file-attribute-user-id
(file-attributes tmp-name1))
@@ -5605,6 +5610,7 @@ Use direct async.")
 (let ((tmp-name1 (tramp--test-make-temp-name nil quoted))
  (tmp-name2 (tramp--test-make-temp-name nil quoted))
  (ange-ftp-make-backup-files t)
+ tramp-allow-unsafe-temporary-files
  ;; These settings are not used by Tramp, so we ignore them.
  version-control delete-old-versions
  (kept-old-versions (default-toplevel-value 'kept-old-versions))
@@ -5715,7 +5721,6 @@ Use direct async.")
  ;; Create temporary file.  T

[elpa] externals/consult 69bbd21 3/3: consult--multi-group: Do not default to category

2021-07-30 Thread ELPA Syncer
branch: externals/consult
commit 69bbd213dc8a98abe94a4f5b1920e3d689d31caa
Author: Daniel Mendler 
Commit: Daniel Mendler 

consult--multi-group: Do not default to category

* The user should explicitly opt-in to a group title
* Avoid allocations in the group function
---
 consult.el | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/consult.el b/consult.el
index 661eb05..2910d6c 100644
--- a/consult.el
+++ b/consult.el
@@ -1894,8 +1894,7 @@ INHERIT-INPUT-METHOD, if non-nil the minibuffer inherits 
the input method."
   "Return title of candidate CAND or TRANSFORM the candidate given SOURCES."
   (if transform
   cand
-(let ((src (consult--multi-source sources cand)))
-  (or (plist-get src :name) (capitalize (symbol-name (plist-get src 
:category)))
+(plist-get (consult--multi-source sources cand) :name)))
 
 (defun consult--multi-preview-key (sources)
   "Return preview keys from SOURCES."



[elpa] externals/consult updated (5564008 -> 69bbd21)

2021-07-30 Thread ELPA Syncer
elpasync pushed a change to branch externals/consult.

  from  5564008   consult--buffer-query: Add :predicate argument
   new  a08e270   Fix #375: Disable completion preview in org source blocks
   new  e5e2bbd   Minor corrections
   new  69bbd21   consult--multi-group: Do not default to category


Summary of changes:
 consult.el | 13 ++---
 1 file changed, 10 insertions(+), 3 deletions(-)



[elpa] externals/consult a08e270 1/3: Fix #375: Disable completion preview in org source blocks

2021-07-30 Thread ELPA Syncer
branch: externals/consult
commit a08e2709e4bae9da8acbcfe58875205384caee38
Author: Daniel Mendler 
Commit: Daniel Mendler 

Fix #375: Disable completion preview in org source blocks
---
 consult.el | 15 +++
 1 file changed, 11 insertions(+), 4 deletions(-)

diff --git a/consult.el b/consult.el
index 313dab2..861952a 100644
--- a/consult.el
+++ b/consult.el
@@ -552,7 +552,7 @@ ARGS is a list of commands or sources followed by the list 
of keyword-value pair
(setq ,list (cdr ,head))
nil)))
 
-;; Upstream bug#46326, Consult issue 
https://github.com/minad/consult/issues/193
+;; Upstream bug#49776, Consult issue 
https://github.com/minad/consult/issues/193
 (defmacro consult--minibuffer-with-setup-hook (fun &rest body)
   "Variant of `minibuffer-with-setup-hook' using a symbol and `fset'.
 
@@ -2081,13 +2081,20 @@ KEYMAP is a command-specific keymap."
 The candidates are previewed in the region from START to END. This function is
 used as the `:state' argument for `consult--read' in the `consult-yank' family
 of functions and in `consult-completion-in-region'."
-  (unless (minibufferp)
+  (unless (or (minibufferp)
+  ;; XXX Disable preview if anything odd is going on with the 
markers. Otherwise we get
+  ;; "Marker points into wrong buffer errors". See
+  ;; https://github.com/minad/consult/issues/375, where Org mode 
source blocks are
+  ;; completed in a different buffer than the original buffer. 
This completion is
+  ;; probably also problematic in my Corfu completion package.
+  (not (eq (window-buffer) (current-buffer)))
+ (and (markerp start) (not (eq (marker-buffer start) 
(current-buffer
+ (and (markerp end) (not (eq (marker-buffer end) 
(current-buffer)
 (let (ov)
   (lambda (cand restore)
 (if restore
 (when ov (delete-overlay ov))
-  (unless ov (setq ov (consult--overlay start end
-'invisible t
+  (unless ov (setq ov (consult--overlay start end 'invisible t
 'window (selected-window
   ;; Use `add-face-text-property' on a copy of "cand in order to merge 
face properties
   (setq cand (copy-sequence cand))



[elpa] externals/consult e5e2bbd 2/3: Minor corrections

2021-07-30 Thread ELPA Syncer
branch: externals/consult
commit e5e2bbdc3a5bcc873a2a43b64535650ed8b1ec4f
Author: Daniel Mendler 
Commit: Daniel Mendler 

Minor corrections
---
 consult.el | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/consult.el b/consult.el
index 861952a..661eb05 100644
--- a/consult.el
+++ b/consult.el
@@ -552,7 +552,7 @@ ARGS is a list of commands or sources followed by the list 
of keyword-value pair
(setq ,list (cdr ,head))
nil)))
 
-;; Upstream bug#49776, Consult issue 
https://github.com/minad/consult/issues/193
+;; Upstream bug#46326, Consult issue 
https://github.com/minad/consult/issues/193
 (defmacro consult--minibuffer-with-setup-hook (fun &rest body)
   "Variant of `minibuffer-with-setup-hook' using a symbol and `fset'.
 
@@ -2094,7 +2094,8 @@ of functions and in `consult-completion-in-region'."
   (lambda (cand restore)
 (if restore
 (when ov (delete-overlay ov))
-  (unless ov (setq ov (consult--overlay start end 'invisible t
+  (unless ov (setq ov (consult--overlay start end
+'invisible t
 'window (selected-window
   ;; Use `add-face-text-property' on a copy of "cand in order to merge 
face properties
   (setq cand (copy-sequence cand))



[elpa] externals/vertico 9de6709: vertico--arrange-candidates: Fix group title highlighting

2021-07-30 Thread ELPA Syncer
branch: externals/vertico
commit 9de6709cddc09740d23d24fb425fa3c174d0e956
Author: Daniel Mendler 
Commit: Daniel Mendler 

vertico--arrange-candidates: Fix group title highlighting
---
 vertico.el | 7 ++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/vertico.el b/vertico.el
index b096bf1..e69c8f7 100644
--- a/vertico.el
+++ b/vertico.el
@@ -491,7 +491,12 @@ The function is configured by BY, BSIZE, BINDEX, BPRED and 
PRED."
   (setq title new-title)
   ;; Restore group title highlighting for prefix titles
   (when (string-prefix-p title str)
-(setq title (substring str 0 (length title)))
+(setq title (substring
+ (car (funcall
+   vertico--highlight-function
+   ;; Remove all properties from the title
+   (list (propertize str 'face 
'vertico-group-title
+ 0 (length title)))
 (vertico--remove-face 0 (length title) 
'completions-first-difference title))
   (push (format group-format title) lines))
 (setcar cand (funcall group-fun str 'transform



[elpa] externals/ivy 20d78ae 1/2: Fix byte-compilation warning on Emacs --without-x

2021-07-30 Thread Basil L. Contovounesios
branch: externals/ivy
commit 20d78ae4fe2b128411f0ddb0aa22ba25aa5d6d3f
Author: akater 
Commit: Basil L. Contovounesios 

Fix byte-compilation warning on Emacs --without-x

* ivy.el (ivy--minibuffer-setup): Modify mwheel variables only after
the library has been loaded (PR #2900).

Copyright-paperwork-exempt: yes
---
 ivy.el | 7 +--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/ivy.el b/ivy.el
index 659ba3e..c693ab7 100644
--- a/ivy.el
+++ b/ivy.el
@@ -2986,8 +2986,11 @@ tries to ensure that it does not change depending on the 
number of candidates."
 
 (defun ivy--minibuffer-setup ()
   "Setup ivy completion in the minibuffer."
-  (setq-local mwheel-scroll-up-function 'ivy-next-line)
-  (setq-local mwheel-scroll-down-function 'ivy-previous-line)
+  ;; Guard for --without-x builds where `mwheel' is not preloaded.
+  (when (boundp 'mwheel-scroll-up-function)
+(setq-local mwheel-scroll-up-function 'ivy-next-line))
+  (when (boundp 'mwheel-scroll-down-function)
+(setq-local mwheel-scroll-down-function 'ivy-previous-line))
   (setq-local completion-show-inline-help nil)
   (setq-local line-spacing nil)
   (setq-local minibuffer-default-add-function



[elpa] externals/ivy 44f1408 2/2: Merge branch 'master' into externals/ivy

2021-07-30 Thread Basil L. Contovounesios
branch: externals/ivy
commit 44f1408664188bea70c977ce0fd1112b9f3b27a9
Merge: 7ba793d 20d78ae
Author: Basil L. Contovounesios 
Commit: Basil L. Contovounesios 

Merge branch 'master' into externals/ivy
---
 ivy.el | 7 +--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/ivy.el b/ivy.el
index 659ba3e..c693ab7 100644
--- a/ivy.el
+++ b/ivy.el
@@ -2986,8 +2986,11 @@ tries to ensure that it does not change depending on the 
number of candidates."
 
 (defun ivy--minibuffer-setup ()
   "Setup ivy completion in the minibuffer."
-  (setq-local mwheel-scroll-up-function 'ivy-next-line)
-  (setq-local mwheel-scroll-down-function 'ivy-previous-line)
+  ;; Guard for --without-x builds where `mwheel' is not preloaded.
+  (when (boundp 'mwheel-scroll-up-function)
+(setq-local mwheel-scroll-up-function 'ivy-next-line))
+  (when (boundp 'mwheel-scroll-down-function)
+(setq-local mwheel-scroll-down-function 'ivy-previous-line))
   (setq-local completion-show-inline-help nil)
   (setq-local line-spacing nil)
   (setq-local minibuffer-default-add-function



[elpa] externals/corfu f3e26ee: Set tab-bar-format to nil (Emacs 28)

2021-07-30 Thread ELPA Syncer
branch: externals/corfu
commit f3e26eeec42f8bd293ffb698333fa48f8635b4f5
Author: Daniel Mendler 
Commit: Daniel Mendler 

Set tab-bar-format to nil (Emacs 28)

Thanks, @protesilaos
---
 corfu.el | 1 +
 1 file changed, 1 insertion(+)

diff --git a/corfu.el b/corfu.el
index 3529608..2439821 100644
--- a/corfu.el
+++ b/corfu.el
@@ -255,6 +255,7 @@ completion began less than that number of seconds ago."
   '((mode-line-format . nil)
 (header-line-format . nil)
 (tab-line-format . nil)
+(tab-bar-format . nil) ;; Emacs 28 tab-bar-format
 (frame-title-format . "")
 (truncate-lines . t)
 (cursor-in-non-selected-windows . nil)



[nongnu] elpa/tuareg updated (b59c422 -> 465b61f)

2021-07-30 Thread ELPA Syncer
elpasync pushed a change to branch elpa/tuareg.

  from  b59c422   Merge commit 'refs/pull/254/head' of 
github.com:/ocaml/tuareg into elpa/tuareg
   new  64fada7   Rewrite `tuareg--error-regexp` in rx
   new  b4d09cd   Remove duplicates from 
compilation-error-regexp-alist{-alist}
   new  aa57258   Recognise new warning format in compilation output
   new  8c8d217   Simpler matching of ending line and character in compiler 
message
   new  00c4cf8   Match source locations in exception backtraces
   new  916c551   Add ERT test of compilation and backtrace messages
   new  c6c49d4   Compensate for end-columns in OCaml messages being off by 
one
   new  0f49e65   Only fontify known @-tags in doc-markup face
   new  a06468c   Repair handling of ocamldoc section headers like {2:text}
   new  465b61f   Merge commit 'refs/pull/258/head' of 
github.com:/ocaml/tuareg into elpa/tuareg


Summary of changes:
 compilation.txt |  36 +++
 tuareg-tests.el | 140 
 tuareg.el   |  84 ++
 3 files changed, 241 insertions(+), 19 deletions(-)



[nongnu] elpa/tuareg 00c4cf8 06/10: Match source locations in exception backtraces

2021-07-30 Thread ELPA Syncer
branch: elpa/tuareg
commit 00c4cf8a233a8d1cd27563edf9a2625a8b1c9e12
Author: Mattias Engdegård 
Commit: Mattias Engdegård 

Match source locations in exception backtraces

We overload the compilation error regexp for this purpose since the
formats are almost the same.
---
 compilation.txt | 28 
 tuareg.el   | 15 ---
 2 files changed, 40 insertions(+), 3 deletions(-)

diff --git a/compilation.txt b/compilation.txt
index 7350995..736066d 100644
--- a/compilation.txt
+++ b/compilation.txt
@@ -120,3 +120,31 @@ File "moo.ml", line 6, characters 6-10:
 6 |   let fish = 13 in
   
 Warning 26 [unused-var]: unused variable fish.
+
+
+* Backtrace messages
+
+Before 4.11:
+
+OCAMLRUNPARAM=b ./bad
+Fatal error: exception Bad.Disaster("oh no!")
+Raised at file "bad.ml", line 5, characters 4-22
+Called from file "bad.ml" (inlined), line 9, characters 2-5
+Called from file "bad.ml", line 12, characters 8-18
+
+4.11 and later:
+
+OCAMLRUNPARAM=b ./bad
+Fatal error: exception Bad.Disaster("oh no!")
+Raised at Bad.f in file "bad.ml", line 5, characters 4-22
+Called from Bad.g in file "bad.ml" (inlined), line 9, characters 2-5
+Called from Bad in file "bad.ml", line 12, characters 8-18
+
+OCAMLRUNPARAM=b ./bad
+Fatal error: exception Sys_error("non.existing.file: No such file or 
directory")
+Raised by primitive operation at Stdlib.open_in_gen in file "stdlib.ml", line 
399, characters 28-54
+Called from Bad.h in file "bad.ml", line 7, characters 13-40
+Called from Bad.f in file "bad.ml", line 13, characters 4-7
+Re-raised at Bad.f in file "bad.ml", line 14, characters 12-19
+Called from Bad.g in file "bad.ml", line 17, characters 2-5
+Called from Bad in file "bad.ml", line 20, characters 8-18
diff --git a/tuareg.el b/tuareg.el
index 18a5044..9e3b243 100644
--- a/tuareg.el
+++ b/tuareg.el
@@ -3152,17 +3152,25 @@ Short cuts for interactions with the REPL:
   (rx bol
   (* " ")
   (group; 1: HIGHLIGHT
-   "File "
+   (or "File "
+   ;; Exception backtrace.
+   (seq
+(or "Raised at" "Re-raised at" "Raised by primitive operation at"
+"Called from")
+(* nonl); OCaml ≥4.11: " FUNCTION in"
+" file "))
(group (? "\"")) ; 2
(group (+ (not (in "\t\n \",<>"  ; 3: FILE
(backref 2)
+   (? " (inlined)")
", line" (? "s") " "
(group (+ (in "0-9")))   ; 4: LINE-START
(? "-" (group (+ (in "0-9"   ; 5; LINE-END
(? ", character" (? "s") " "
   (group (+ (in "0-9"))); 6: COL-START
   (? "-" (group (+ (in "0-9")   ; 7: COL-END
-   ":")
+   ;; Colon not present in backtraces.
+   (? ":"))
   (? "\n"
  (* (in "\t "))
  (* (or (seq (+ (in "0-9"))
@@ -3175,7 +3183,8 @@ Short cuts for interactions with the REPL:
 (? " " (+ (in "0-9")))
 (? " [" (+ (in "a-z0-9-")) "]")
 ":")))
-  "Regular expression matching the error messages produced by 
ocamlc/ocamlopt.")
+  "Regular expression matching the error messages produced by ocamlc/ocamlopt.
+Also matches source references in exception backtraces.")
 
 (when (boundp 'compilation-error-regexp-alist-alist)
   (setq compilation-error-regexp-alist-alist



[nongnu] elpa/tuareg 64fada7 01/10: Rewrite `tuareg--error-regexp` in rx

2021-07-30 Thread ELPA Syncer
branch: elpa/tuareg
commit 64fada7f1abbcc78359155a0ab4640e6b0fef0f6
Author: Mattias Engdegård 
Commit: Mattias Engdegård 

Rewrite `tuareg--error-regexp` in rx

Much more readable and maintainable. The regexp remains unchanged;
mechanised conversion to rx guarantees equivalence.
---
 tuareg.el | 32 +++-
 1 file changed, 27 insertions(+), 5 deletions(-)

diff --git a/tuareg.el b/tuareg.el
index f8ecab0..8cf560c 100644
--- a/tuareg.el
+++ b/tuareg.el
@@ -3149,11 +3149,33 @@ Short cuts for interactions with the REPL:
 ;; the language is not English.  Hence we add a regexp.
 
 (defconst tuareg--error-regexp
-  "^ *\\(File \\(\"?\\)\\([^,\" \n\t<>]+\\)\\2, \
-lines? \\([0-9]+\\)-?\\([0-9]+\\)?\
-\\(?:, characters? \\([0-9]+\\)-?\\([0-9]+\\)?\\)?:\\)\
-\\(?:\n[ \t]*\\(?:\\(?:[0-9]+ | .*\\|\\^+\\)\n[ \t]*\\)*\
-\\(Warning\\(?: [0-9]+\\)?\\):\\)?"
+  (rx bol
+  (* " ")
+  (group; 1: HIGHLIGHT
+   "File "
+   (group (? "\"")) ; 2
+   (group (+ (not (in "\t\n \",<>"  ; 3: FILE
+   (backref 2)
+   ", line" (? "s") " "
+   (group (+ (in "0-9")))   ; 4: LINE-START
+   (? "-")
+   (? (group (+ (in "0-9"   ; 5; LINE-END
+   (? ", character" (? "s") " "
+  (group (+ (in "0-9"))); 6: COL-START
+  (? "-")
+  (? (group (+ (in "0-9")   ; 7: COL-END
+   ":")
+  (? "\n"
+ (* (in "\t "))
+ (* (or (seq (+ (in "0-9"))
+ " | "
+ (* nonl))
+(+ "^"))
+"\n"
+(* (in "\t ")))
+ (group "Warning"   ; 8: WARNING
+(? " " (+ (in "0-9"
+ ":"))
   "Regular expression matching the error messages produced by 
ocamlc/ocamlopt.")
 
 (when (boundp 'compilation-error-regexp-alist-alist)



[nongnu] elpa/tuareg a06468c 09/10: Repair handling of ocamldoc section headers like {2:text}

2021-07-30 Thread ELPA Syncer
branch: elpa/tuareg
commit a06468cbbc2b26b6c36637da9c728a7da2e0d1f4
Author: Mattias Engdegård 
Commit: Mattias Engdegård 

Repair handling of ocamldoc section headers like {2:text}
---
 tuareg.el | 23 ---
 1 file changed, 12 insertions(+), 11 deletions(-)

diff --git a/tuareg.el b/tuareg.el
index 088c91c..e7baa3b 100644
--- a/tuareg.el
+++ b/tuareg.el
@@ -764,12 +764,13 @@ delimiting the region of interest. "
   (let ((case-fold-search nil))
 (funcall
  (tuareg--syntax-rules
-  ((rx "[")
+  ((rx (or "[" "{["))
;; Fontify opening bracket.
-   (put-text-property start (1+ start) 'face
+   (put-text-property start (point) 'face
   'tuareg-font-lock-doc-markup-face)
;; Skip balanced set of brackets.
-   (let ((level 1))
+   (let ((start-end (point))
+ (level 1))
  (while (and (< (point) end)
  (re-search-forward (rx (? "\\") (in "[]"))
 end 'noerror)
@@ -785,11 +786,11 @@ delimiting the region of interest. "
(forward-char -1)
nil))
 (t t)
- (put-text-property (1+ start) (point) 'face
+ (put-text-property start-end (point) 'face
 tuareg-font-lock-doc-code-face)
  (if (> level 0)
  ;; Highlight unbalanced opening bracket.
- (put-text-property start (1+ start) 'face
+ (put-text-property start start-end 'face
 'tuareg-font-lock-error-face)
;; Fontify closing bracket.
(put-text-property (point) (1+ (point)) 'face
@@ -817,11 +818,11 @@ delimiting the region of interest. "
  (goto-char (match-end 0
 
   ;; Cross-reference.
-  ((rx "{!" (? (or "tag" "module" "modtype" "class"
-"classtype" "val" "type"
-"exception" "attribute" "method"
-"section" "const" "recfield")
-":")
+  ((rx (or "{!" "{{!")
+   (? (or "tag" "module" "modtype" "class" "classtype" "val" "type"
+  "exception" "attribute" "method" "section" "const"
+  "recfield")
+  ":")
 (group (* (in "a-zA-Z0-9" "_.'"
(put-text-property start (match-beginning group) 'face
   'tuareg-font-lock-doc-markup-face)
@@ -847,7 +848,7 @@ delimiting the region of interest. "
 (or (or "-" ":" "_" "^"
 "b" "i" "e" "C" "L" "R"
 "ul" "ol" "%"
-"")
+"{:")
 ;; Section header with optional label.
 (seq (+ digit)
  (? ":"



[nongnu] elpa/tuareg 916c551 07/10: Add ERT test of compilation and backtrace messages

2021-07-30 Thread ELPA Syncer
branch: elpa/tuareg
commit 916c551b67bd6fbdc233a314d0684d9a6ffc04f4
Author: Mattias Engdegård 
Commit: Mattias Engdegård 

Add ERT test of compilation and backtrace messages
---
 tuareg-tests.el | 140 
 1 file changed, 140 insertions(+)

diff --git a/tuareg-tests.el b/tuareg-tests.el
index 720e4ed..a4c6673 100644
--- a/tuareg-tests.el
+++ b/tuareg-tests.el
@@ -1,6 +1,7 @@
 ;;; tests for tuareg.el   -*- lexical-binding: t -*-
 
 (require 'tuareg)
+(require 'compile)
 (require 'ert)
 
 (defconst tuareg-test-dir
@@ -391,4 +392,143 @@ Returns the value of the last FORM."
  (should (equal (tuareg-discover-phrase (point-min))
 (list (point-min) (1- p1) (1- p1)))
 
+(defconst tuareg-test--compilation-messages
+  '((("File \"file.ml\", line 4, characters 6-7:\n"
+  "Error: This expression has type int\n"
+  "This is not a function; it cannot be applied.\n")
+ ((1 error "file.ml" 4 4 6 7)))
+(("File \"file.ml\", line 3, characters 6-7:\n"
+  "Warning 26: unused variable y.\n")
+ ((1 warning "file.ml" 3 3 6 7)))
+
+(("File \"helloworld.ml\", line 2, characters 36-64:\n"
+  "2 | module rec A: sig type t += A end = struct type t += A = B.A end\n"
+  "\n"
+  "Error: Cannot safely evaluate the definition of the following cycle\n"
+  "   of recursively-defined modules: A -> B -> A.\n")
+ ((1 error "helloworld.ml" 2 2 36 64)))
+(("File \"helloworld.ml\", lines 4-7, characters 6-3:\n"
+  "4 | ..struct\n"
+  "5 |   module F(X:sig end) = struct end\n"
+  "6 |   let f () = B.value\n"
+  "7 | end\n"
+  "Error: Cannot safely evaluate the definition of the following cycle\n"
+  "   of recursively-defined modules: A -> B -> A.\n")
+ ((1 error "helloworld.ml" 4 7 6 3)))
+(("File \"robustmatch.ml\", lines 33-37, characters 6-23:\n"
+  " 9 | ..match t1, t2, x with\n"
+  "10 |   | AB, AB, A -> ()\n"
+  "11 |   | MAB, _, A -> ()\n"
+  "12 |   | _,  AB, B -> ()\n"
+  "13 |   | _, MAB, B -> ()\n"
+  "Warning 8: this pattern-matching is not exhaustive.\n"
+  "Here is an example of a case that is not matched:\n"
+  "(AB, MAB, A)\n")
+ ((1 warning "robustmatch.ml" 33 37 6 23)))
+(("File \"robustmatch.ml\", lines 33-37, characters 6-23:\n"
+  " 9 | ..match t1, t2, x with\n"
+  "10 |   | AB, AB, A -> ()\n"
+  "11 |   | MAB, _, A -> ()\n"
+  "12 |   | _,  AB, B -> ()\n"
+  "13 |   | _, MAB, B -> ()\n"
+  "Warning 8 [partial-match]: this pattern-matching is not exhaustive.\n"
+  "Here is an example of a case that is not matched:\n"
+  "(AB, MAB, A)\n")
+ ((1 warning "robustmatch.ml" 33 37 6 23)))
+(("File \"main.ml\", line 13, characters 34-35:\n"
+  "13 |   let f : M.t -> M.t = fun M.C -> y\n"
+  "   ^\n"
+  "Error: This expression has type M/2.t but an expression was expected of 
type\n"
+  " M/1.t\n"
+  "   File \"main.ml\", line 10, characters 2-41:\n"
+  " Definition of module M/1\n"
+  "   File \"main.ml\", line 7, characters 0-32:\n"
+  " Definition of module M/2\n")
+ ((1 error "main.ml" 13 13 34 35)
+  (225 error "main.ml" 10 10 2 41)
+  (308 error "main.ml" 7 7 0 32)))
+(("Fatal error: exception Bad.Disaster(\"oh no!\")\n"
+  "Raised at file \"bad.ml\", line 5, characters 4-22\n"
+  "Called from file \"worse.ml\" (inlined), line 9, characters 2-5\n"
+  "Called from file \"worst.ml\", line 12, characters 8-18\n")
+ ((47 error "bad.ml" 5 5 4 22)
+  (96 error "worse.ml" 9 9 2 5)
+  (158 error "worst.ml" 12 12 8 18)))
+(("Fatal error: exception Bad.Disaster(\"oh no!\")\n"
+  "Raised at Bad.f in file \"bad.ml\", line 5, characters 4-22\n"
+  "Called from Bad.g in file \"worse.ml\" (inlined), line 9, characters 
2-5\n"
+  "Called from Bad in file \"worst.ml\", line 12, characters 8-18\n")
+ ((47 error "bad.ml" 5 5 4 22)
+  (105 error "worse.ml" 9 9 2 5)
+  (176 error "worst.ml" 12 12 8 18)))
+(("Fatal error: exception Hell\n"
+  "Raised by primitive operation at Murky.depths in file \"inferno.ml\", 
line 399, characters 28-54\n"
+  "Called from Nasty.f in file \"nasty.ml\", line 7, characters 13-40\n"
+  "Re-raised at Smelly.f in file \"smelly.ml\", line 14, characters 
12-19\n"
+  "Called from Rubbish.g in file \"rubbish.ml\", line 17, characters 
2-5\n")
+ ((29 error "inferno.ml" 399 399 28 54)
+  (124 error "nasty.ml" 7 7 13 40)
+  (189 error "smelly.ml" 14 14 12 19)
+  (258 error "rubbish.ml" 17 17 2 5
+  "Compilation message test data.
+Each element is (STRINGS ERRORS) where
+
+ STRINGS is a list of strings forming the message when concatenated
+

[nongnu] elpa/tuareg c6c49d4 08/10: Compensate for end-columns in OCaml messages being off by one

2021-07-30 Thread ELPA Syncer
branch: elpa/tuareg
commit c6c49d4fb654bd6dc69a0220cec731172a0c6a01
Author: Mattias Engdegård 
Commit: Mattias Engdegård 

Compensate for end-columns in OCaml messages being off by one

OCaml messages use exclusive end columns but Emacs expects them to
be inclusive. In other words, when OCaml says "characters 23-45",
tell Emacs to use columns 23..44, zero-based.
To complicate matters, Emacs 27 and earlier had an off-by-one bug
in the end-column function call code that we need for compensate for.
---
 tuareg-tests.el | 38 +++---
 tuareg.el   | 11 ++-
 2 files changed, 29 insertions(+), 20 deletions(-)

diff --git a/tuareg-tests.el b/tuareg-tests.el
index a4c6673..095a007 100644
--- a/tuareg-tests.el
+++ b/tuareg-tests.el
@@ -396,17 +396,17 @@ Returns the value of the last FORM."
   '((("File \"file.ml\", line 4, characters 6-7:\n"
   "Error: This expression has type int\n"
   "This is not a function; it cannot be applied.\n")
- ((1 error "file.ml" 4 4 6 7)))
+ ((1 error "file.ml" 4 4 6 6)))
 (("File \"file.ml\", line 3, characters 6-7:\n"
   "Warning 26: unused variable y.\n")
- ((1 warning "file.ml" 3 3 6 7)))
+ ((1 warning "file.ml" 3 3 6 6)))
 
 (("File \"helloworld.ml\", line 2, characters 36-64:\n"
   "2 | module rec A: sig type t += A end = struct type t += A = B.A end\n"
   "\n"
   "Error: Cannot safely evaluate the definition of the following cycle\n"
   "   of recursively-defined modules: A -> B -> A.\n")
- ((1 error "helloworld.ml" 2 2 36 64)))
+ ((1 error "helloworld.ml" 2 2 36 63)))
 (("File \"helloworld.ml\", lines 4-7, characters 6-3:\n"
   "4 | ..struct\n"
   "5 |   module F(X:sig end) = struct end\n"
@@ -414,7 +414,7 @@ Returns the value of the last FORM."
   "7 | end\n"
   "Error: Cannot safely evaluate the definition of the following cycle\n"
   "   of recursively-defined modules: A -> B -> A.\n")
- ((1 error "helloworld.ml" 4 7 6 3)))
+ ((1 error "helloworld.ml" 4 7 6 2)))
 (("File \"robustmatch.ml\", lines 33-37, characters 6-23:\n"
   " 9 | ..match t1, t2, x with\n"
   "10 |   | AB, AB, A -> ()\n"
@@ -424,7 +424,7 @@ Returns the value of the last FORM."
   "Warning 8: this pattern-matching is not exhaustive.\n"
   "Here is an example of a case that is not matched:\n"
   "(AB, MAB, A)\n")
- ((1 warning "robustmatch.ml" 33 37 6 23)))
+ ((1 warning "robustmatch.ml" 33 37 6 22)))
 (("File \"robustmatch.ml\", lines 33-37, characters 6-23:\n"
   " 9 | ..match t1, t2, x with\n"
   "10 |   | AB, AB, A -> ()\n"
@@ -434,7 +434,7 @@ Returns the value of the last FORM."
   "Warning 8 [partial-match]: this pattern-matching is not exhaustive.\n"
   "Here is an example of a case that is not matched:\n"
   "(AB, MAB, A)\n")
- ((1 warning "robustmatch.ml" 33 37 6 23)))
+ ((1 warning "robustmatch.ml" 33 37 6 22)))
 (("File \"main.ml\", line 13, characters 34-35:\n"
   "13 |   let f : M.t -> M.t = fun M.C -> y\n"
   "   ^\n"
@@ -444,32 +444,32 @@ Returns the value of the last FORM."
   " Definition of module M/1\n"
   "   File \"main.ml\", line 7, characters 0-32:\n"
   " Definition of module M/2\n")
- ((1 error "main.ml" 13 13 34 35)
-  (225 error "main.ml" 10 10 2 41)
-  (308 error "main.ml" 7 7 0 32)))
+ ((1 error "main.ml" 13 13 34 34)
+  (225 error "main.ml" 10 10 2 40)
+  (308 error "main.ml" 7 7 0 31)))
 (("Fatal error: exception Bad.Disaster(\"oh no!\")\n"
   "Raised at file \"bad.ml\", line 5, characters 4-22\n"
   "Called from file \"worse.ml\" (inlined), line 9, characters 2-5\n"
   "Called from file \"worst.ml\", line 12, characters 8-18\n")
- ((47 error "bad.ml" 5 5 4 22)
-  (96 error "worse.ml" 9 9 2 5)
-  (158 error "worst.ml" 12 12 8 18)))
+ ((47 error "bad.ml" 5 5 4 21)
+  (96 error "worse.ml" 9 9 2 4)
+  (158 error "worst.ml" 12 12 8 17)))
 (("Fatal error: exception Bad.Disaster(\"oh no!\")\n"
   "Raised at Bad.f in file \"bad.ml\", line 5, characters 4-22\n"
   "Called from Bad.g in file \"worse.ml\" (inlined), line 9, characters 
2-5\n"
   "Called from Bad in file \"worst.ml\", line 12, characters 8-18\n")
- ((47 error "bad.ml" 5 5 4 22)
-  (105 error "worse.ml" 9 9 2 5)
-  (176 error "worst.ml" 12 12 8 18)))
+ ((47 error "bad.ml" 5 5 4 21)
+  (105 error "worse.ml" 9 9 2 4)
+  (176 error "worst.ml" 12 12 8 17)))
 (("Fatal error: exception Hell\n"
   "Raised by primitive operation at Murky.depths in file \"inferno.ml\", 
line 399, characters 28-54\n"
   "Called from Nasty.f in file \"nasty.ml\", line 7, characters 13-40\n"
   "Re-raised at Smelly.f in file \"smelly.ml\", l

[nongnu] elpa/tuareg 0f49e65 02/10: Only fontify known @-tags in doc-markup face

2021-07-30 Thread ELPA Syncer
branch: elpa/tuareg
commit 0f49e65bfc90f6a9d0a0ab05ac48146072d48827
Author: Mattias Engdegård 
Commit: Mattias Engdegård 

Only fontify known @-tags in doc-markup face

Help the programmer by not fontifying unknown @-tags, likely to be
misspellings.
---
 tuareg.el | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/tuareg.el b/tuareg.el
index f8ecab0..088c91c 100644
--- a/tuareg.el
+++ b/tuareg.el
@@ -801,7 +801,9 @@ delimiting the region of interest. "
   'tuareg-font-lock-error-face))
 
   ;; @-tag.
-  ((rx "@" (group (+ (in "a-z" "_"
+  ((rx "@" (group (or "author" "deprecated" "param" "raise" "return"
+  "see" "since" "before" "version"))
+   word-end)
(put-text-property start (point) 'face
   'tuareg-font-lock-doc-markup-face)
;; Use code face for the first argument of some tags.



[nongnu] elpa/tuareg aa57258 04/10: Recognise new warning format in compilation output

2021-07-30 Thread ELPA Syncer
branch: elpa/tuareg
commit aa57258fb7ab9244f63624543149b869a6eb7706
Author: Mattias Engdegård 
Commit: Mattias Engdegård 

Recognise new warning format in compilation output

Make `tuareg--error-regexp` match warnings from OCaml 4.12 where they
are displayed with mnemonics.
---
 compilation.txt | 8 
 tuareg.el   | 5 +++--
 2 files changed, 11 insertions(+), 2 deletions(-)

diff --git a/compilation.txt b/compilation.txt
index de91d38..7350995 100644
--- a/compilation.txt
+++ b/compilation.txt
@@ -112,3 +112,11 @@ Warning 3: This expression has type M/2.t but an 
expression was expected of type
  Definition of module M/1
File "main.ml", line 7, characters 0-32:
  Definition of module M/2
+
+
+* Since OCaml 4.12, warnings come with mnemonics.
+
+File "moo.ml", line 6, characters 6-10:
+6 |   let fish = 13 in
+  
+Warning 26 [unused-var]: unused variable fish.
diff --git a/tuareg.el b/tuareg.el
index 955ab45..d6653d6 100644
--- a/tuareg.el
+++ b/tuareg.el
@@ -3174,8 +3174,9 @@ Short cuts for interactions with the REPL:
 "\n"
 (* (in "\t ")))
  (group "Warning"   ; 8: WARNING
-(? " " (+ (in "0-9"
- ":"))
+(? " " (+ (in "0-9")))
+(? " [" (+ (in "a-z0-9-")) "]")
+":")))
   "Regular expression matching the error messages produced by 
ocamlc/ocamlopt.")
 
 (when (boundp 'compilation-error-regexp-alist-alist)



[nongnu] elpa/tuareg 465b61f 10/10: Merge commit 'refs/pull/258/head' of github.com:/ocaml/tuareg into elpa/tuareg

2021-07-30 Thread ELPA Syncer
branch: elpa/tuareg
commit 465b61fddcb9556a3e5a10b9654b3aff537022f4
Merge: c6c49d4 a06468c
Author: Stefan Monnier 
Commit: Stefan Monnier 

Merge commit 'refs/pull/258/head' of github.com:/ocaml/tuareg into 
elpa/tuareg
---
 tuareg.el | 27 +++
 1 file changed, 15 insertions(+), 12 deletions(-)

diff --git a/tuareg.el b/tuareg.el
index 4f92def..ad73cfa 100644
--- a/tuareg.el
+++ b/tuareg.el
@@ -764,12 +764,13 @@ delimiting the region of interest. "
   (let ((case-fold-search nil))
 (funcall
  (tuareg--syntax-rules
-  ((rx "[")
+  ((rx (or "[" "{["))
;; Fontify opening bracket.
-   (put-text-property start (1+ start) 'face
+   (put-text-property start (point) 'face
   'tuareg-font-lock-doc-markup-face)
;; Skip balanced set of brackets.
-   (let ((level 1))
+   (let ((start-end (point))
+ (level 1))
  (while (and (< (point) end)
  (re-search-forward (rx (? "\\") (in "[]"))
 end 'noerror)
@@ -785,11 +786,11 @@ delimiting the region of interest. "
(forward-char -1)
nil))
 (t t)
- (put-text-property (1+ start) (point) 'face
+ (put-text-property start-end (point) 'face
 tuareg-font-lock-doc-code-face)
  (if (> level 0)
  ;; Highlight unbalanced opening bracket.
- (put-text-property start (1+ start) 'face
+ (put-text-property start start-end 'face
 'tuareg-font-lock-error-face)
;; Fontify closing bracket.
(put-text-property (point) (1+ (point)) 'face
@@ -801,7 +802,9 @@ delimiting the region of interest. "
   'tuareg-font-lock-error-face))
 
   ;; @-tag.
-  ((rx "@" (group (+ (in "a-z" "_"
+  ((rx "@" (group (or "author" "deprecated" "param" "raise" "return"
+  "see" "since" "before" "version"))
+   word-end)
(put-text-property start (point) 'face
   'tuareg-font-lock-doc-markup-face)
;; Use code face for the first argument of some tags.
@@ -815,11 +818,11 @@ delimiting the region of interest. "
  (goto-char (match-end 0
 
   ;; Cross-reference.
-  ((rx "{!" (? (or "tag" "module" "modtype" "class"
-"classtype" "val" "type"
-"exception" "attribute" "method"
-"section" "const" "recfield")
-":")
+  ((rx (or "{!" "{{!")
+   (? (or "tag" "module" "modtype" "class" "classtype" "val" "type"
+  "exception" "attribute" "method" "section" "const"
+  "recfield")
+  ":")
 (group (* (in "a-zA-Z0-9" "_.'"
(put-text-property start (match-beginning group) 'face
   'tuareg-font-lock-doc-markup-face)
@@ -845,7 +848,7 @@ delimiting the region of interest. "
 (or (or "-" ":" "_" "^"
 "b" "i" "e" "C" "L" "R"
 "ul" "ol" "%"
-"")
+"{:")
 ;; Section header with optional label.
 (seq (+ digit)
  (? ":"



[nongnu] elpa/tuareg b4d09cd 03/10: Remove duplicates from compilation-error-regexp-alist{-alist}

2021-07-30 Thread ELPA Syncer
branch: elpa/tuareg
commit b4d09cd60e68fe4797e6e7f03099527845c94f5a
Author: Mattias Engdegård 
Commit: Mattias Engdegård 

Remove duplicates from compilation-error-regexp-alist{-alist}

This makes it easier to test changes by re-evaluating the file
without accretion of junk in these variables.
---
 tuareg.el | 4 
 1 file changed, 4 insertions(+)

diff --git a/tuareg.el b/tuareg.el
index 8cf560c..955ab45 100644
--- a/tuareg.el
+++ b/tuareg.el
@@ -3179,11 +3179,15 @@ Short cuts for interactions with the REPL:
   "Regular expression matching the error messages produced by 
ocamlc/ocamlopt.")
 
 (when (boundp 'compilation-error-regexp-alist-alist)
+  (setq compilation-error-regexp-alist-alist
+(assq-delete-all 'ocaml compilation-error-regexp-alist-alist))
   (push `(ocaml ,tuareg--error-regexp 3 (4 . 5) (6 . 7) (8) 1
 (8 font-lock-function-name-face))
 compilation-error-regexp-alist-alist))
 
 (when (boundp 'compilation-error-regexp-alist)
+  (setq compilation-error-regexp-alist
+(delq 'ocaml compilation-error-regexp-alist))
   (push 'ocaml compilation-error-regexp-alist)
 
   (eval-after-load 'caml



[nongnu] elpa/tuareg 8c8d217 05/10: Simpler matching of ending line and character in compiler message

2021-07-30 Thread ELPA Syncer
branch: elpa/tuareg
commit 8c8d217bf1f4227b76da0c7f85371c38c091392d
Author: Mattias Engdegård 
Commit: Mattias Engdegård 

Simpler matching of ending line and character in compiler message

If there is no `-`, there won't be any number following.
---
 tuareg.el | 6 ++
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/tuareg.el b/tuareg.el
index d6653d6..18a5044 100644
--- a/tuareg.el
+++ b/tuareg.el
@@ -3158,12 +3158,10 @@ Short cuts for interactions with the REPL:
(backref 2)
", line" (? "s") " "
(group (+ (in "0-9")))   ; 4: LINE-START
-   (? "-")
-   (? (group (+ (in "0-9"   ; 5; LINE-END
+   (? "-" (group (+ (in "0-9"   ; 5; LINE-END
(? ", character" (? "s") " "
   (group (+ (in "0-9"))); 6: COL-START
-  (? "-")
-  (? (group (+ (in "0-9")   ; 7: COL-END
+  (? "-" (group (+ (in "0-9")   ; 7: COL-END
":")
   (? "\n"
  (* (in "\t "))



[elpa] externals/javaimp 7096049: * javaimp-parse.el: Fix class scope parsing when declaration contains Enum class name

2021-07-30 Thread Filipp Gunbin
branch: externals/javaimp
commit 7096049eaa7a5f7bddedb3baf4fac51c94a5aa86
Author: Filipp Gunbin 
Commit: Filipp Gunbin 

* javaimp-parse.el: Fix class scope parsing when declaration contains Enum 
class name
---
 javaimp-parse.el | 21 +
 javaimp-tests.el |  2 ++
 javaimp-util.el  | 14 --
 3 files changed, 19 insertions(+), 18 deletions(-)

diff --git a/javaimp-parse.el b/javaimp-parse.el
index e123c2a..fca0369 100644
--- a/javaimp-parse.el
+++ b/javaimp-parse.el
@@ -73,6 +73,19 @@ present."
 (string-trim (substring str 0 end))
   str)))
 
+(defun javaimp--parse-rsb-keyword (regexp &optional bound noerror count)
+  "Like `re-search-backward', but count only occurences outside
+syntactic context as given by `syntax-ppss-context'.  Assumes
+point is outside of any context initially."
+  (or count (setq count 1))
+  (let ((step (if (>= count 0) 1 -1))
+(case-fold-search nil)
+res)
+(dotimes (_ (abs count))
+  (while (and (setq res (re-search-backward regexp bound noerror step))
+  (syntax-ppss-context (syntax-ppss)
+res))
+
 (defun javaimp--parse-arglist (beg end &optional only-type)
   "Parse arg list between BEG and END, of the form 'TYPE NAME,
 ...'.  Return list of conses (TYPE . NAME).  If ONLY-TYPE is
@@ -178,7 +191,7 @@ is checked to be SKIP-COUNT lists away from the SCOPE-START 
(1 is
 for scope start itself, so if you want to skip one additional
 list, use 2 etc.).  If a match is found, then match-data is set,
 as for `re-search-backward'."
-  (and (javaimp--rsb-outside-context regexp nil t)
+  (and (javaimp--parse-rsb-keyword regexp nil t)
(ignore-errors
  ;; Does our match belong to the right block?
  (= (scan-lists (match-end 0) (or skip-count 1) -1)
@@ -192,7 +205,7 @@ is left before the match.  Otherwise, the result is nil and 
point
 is unchanged."
   (let ((pos (point)))
 (catch 'found
-  (while (javaimp--rsb-outside-context regexp bound t)
+  (while (javaimp--parse-rsb-keyword regexp bound t)
 (let ((scan-pos (match-end 0)))
   (javaimp--parse-with-arglist-syntax scan-pos
 (while (and scan-pos (<= scan-pos (nth 1 state)))
@@ -403,14 +416,14 @@ nil then goes all the way up."
 
 (defun javaimp--parse-get-package ()
   (goto-char (point-max))
-  (when (javaimp--rsb-outside-context
+  (when (javaimp--parse-rsb-keyword
  "^\\s-*package\\s-+\\([^;\n]+\\)\\s-*;" nil t 1)
 (match-string 1)))
 
 (defun javaimp--parse-get-file-classes ()
   (goto-char (point-max))
   (let (res)
-(while (javaimp--rsb-outside-context
+(while (javaimp--parse-rsb-keyword
 (regexp-opt javaimp--parse-class-keywords 'words) nil t)
   (save-excursion
 (let ((parse-sexp-ignore-comments t) ; FIXME remove with major mode
diff --git a/javaimp-tests.el b/javaimp-tests.el
index d46ee37..0ca4593 100644
--- a/javaimp-tests.el
+++ b/javaimp-tests.el
@@ -58,6 +58,8 @@ implements Interface1, Interface2 {"
   class "Foo")
 '("class Foo {"
   class "Foo")
+'("class Foo> {"
+  class "Foo")
 '("class Foo> \
 extends Bar> {"
   class "Foo")
diff --git a/javaimp-util.el b/javaimp-util.el
index 0231f17..1544cc4 100644
--- a/javaimp-util.el
+++ b/javaimp-util.el
@@ -137,20 +137,6 @@ buffer and returns its result"
   (concat "[" path-separator "\n]+")
   t)))
 
-
-(defun javaimp--rsb-outside-context (regexp &optional bound noerror count)
-  "Like `re-search-backward', but count only occurences outside
-syntactic context as given by `syntax-ppss-context'.  Assumes
-point is outside of any context initially."
-  (or count (setq count 1))
-  (let ((step (if (>= count 0) 1 -1))
-res)
-(dotimes (_ (abs count))
-  (while (and (setq res (re-search-backward regexp bound noerror step))
-  (syntax-ppss-context (syntax-ppss)
-res))
-
-
 
 ;; Tree building & search
 



[elpa] branch scratch/javaimp-wip created (now 86cd3b9)

2021-07-30 Thread Filipp Gunbin
fgunbin pushed a change to branch scratch/javaimp-wip.

at  86cd3b9   wip

This branch includes the following new commits:

   new  86cd3b9   wip




[elpa] scratch/javaimp-wip 86cd3b9: wip

2021-07-30 Thread Filipp Gunbin
branch: scratch/javaimp-wip
commit 86cd3b9b9eb8f0da4d873cac2ead1475d2ed986f
Author: Filipp Gunbin 
Commit: Filipp Gunbin 

wip
---
 javaimp-parse.el | 101 +--
 javaimp.el   |  20 +--
 2 files changed, 87 insertions(+), 34 deletions(-)

diff --git a/javaimp-parse.el b/javaimp-parse.el
index fca0369..db58e0e 100644
--- a/javaimp-parse.el
+++ b/javaimp-parse.el
@@ -335,6 +335,7 @@ those may later become 'local-class' (see 
`javaimp--parse-scopes')."
(javaimp--parse-skip-back-until)
(= (char-before) ?\)))
  (ignore-errors
+   ;; for method this is arglist
(goto-char
 (scan-lists (point) -1 0
 (let* (;; leave open/close parens out
@@ -367,14 +368,14 @@ those may later become 'local-class' (see 
`javaimp--parse-scopes')."
   "Attempts to parse 'array' scope."
   (save-excursion
 (and (javaimp--parse-skip-back-until)
- (member (char-before) '(?, ?{ ?\]))
+ (member (char-before) '(?, ?\]))
  (make-javaimp-scope :type 'array
  :name ""
  :start nil
  :open-brace (nth 1 state)
 
 (defun javaimp--parse-scope-unknown (state)
-  "Catch-all parser which produces `unknown' scope."
+  "Catch-all parser which produces 'unknown' scope."
   (make-javaimp-scope :type 'unknown
   :name "unknown"
   :start nil
@@ -382,34 +383,50 @@ those may later become 'local-class' (see 
`javaimp--parse-scopes')."
 
 (defun javaimp--parse-scopes (count)
   "Attempts to parse COUNT enclosing scopes at point.  If COUNT is
-nil then goes all the way up."
-  (let ((state (syntax-ppss)) res)
+nil then goes all the way up.  Examines and sets property
+'javaimp-parse-scope' at each scope's open brace."
+  (let ((state (syntax-ppss))
+res)
 (unless (syntax-ppss-context state)
-  (save-excursion
-(while (and (nth 1 state)
-(or (not count)
-(>= (setq count (1- count)) 0)))
-  ;; find innermost enclosing open-bracket
-  (goto-char (nth 1 state))
-  (when (= (char-after) ?{)
-(let ((scope (run-hook-with-args-until-success
-  'javaimp--parse-scope-hook state)))
-  (push scope res)
-  (if (javaimp-scope-start scope)
-  (goto-char (javaimp-scope-start scope)
-  (setq state (syntax-ppss)
+  (while (and (nth 1 state)
+  (or (not count)
+  (>= (setq count (1- count)) 0)))
+;; find innermost enclosing open-bracket
+(goto-char (nth 1 state))
+(when (= (char-after) ?{)
+  (let ((scope (get-text-property 'javaimp-parse-scope)))
+(unless scope
+  (setq scope (run-hook-with-args-until-success
+   'javaimp--parse-scope-hook state))
+  (put-text-property (point) (1+ (point))
+ 'javaimp--parse-scope scope))
+(push scope res)
+(if (javaimp-scope-start scope)
+(goto-char (javaimp-scope-start scope)
+(setq state (syntax-ppss
 ;; if a class is enclosed in anything other than a class, then it
 ;; should be local
 (let ((tmp res)
   in-local)
   (while tmp
 (if (javaimp--parse-is-class (car tmp))
-(if in-local
-(setf (javaimp-scope-type (car tmp)) 'local-class))
+(when in-local
+  (setf (javaimp-scope-type (car tmp)) 'local-class))
   (setq in-local t))
 (setq tmp (cdr tmp
 res))
 
+(defun javaimp--parse-all-scopes ()
+  "Parses all scopes in a buffer."
+  (goto-char (point-max))
+  (let ((parse-sexp-ignore-comments t)  ; FIXME remove with major mode
+(parse-sexp-lookup-properties nil))
+(while (javaimp--parse-rsb-keyword "{" nil t)
+  (save-excursion
+(forward-char)
+;; Set props at this brace and all the way up
+(javaimp--parse-scopes nil)
+
 
 
 ;; Main
@@ -422,18 +439,38 @@ nil then goes all the way up."
 
 (defun javaimp--parse-get-file-classes ()
   (goto-char (point-max))
-  (let (res)
-(while (javaimp--parse-rsb-keyword
-(regexp-opt javaimp--parse-class-keywords 'words) nil t)
-  (save-excursion
-(let ((parse-sexp-ignore-comments t) ; FIXME remove with major mode
-  (parse-sexp-lookup-properties nil))
-  (when (and (ignore-errors
-   (goto-char (scan-lists (point) 1 -1)))
- (= (char-before) ?{))
-(let ((scopes (javaimp--parse-scopes nil)))
-  (when (seq-every-p #'javaimp--parse-is-class scopes)
-(push (mapconcat #'javaimp-scope-name scopes ".") res)

[elpa] externals/ada-mode updated (41efc6e -> b08975f)

2021-07-30 Thread Stephen Leake
stephen_leake pushed a change to branch externals/ada-mode.

  from  41efc6e   Publish ada-mode 7.1.5
   new  565a08d   Minor fixes preparing for 7.1.6 release
   new  f257b28   Fix more byte-compiler style warnings
   new  0f4da3a   Allow compiling in elpa workspace
   new  804cc43   * prj.el: add copyright
   new  b08975f   Release ada-mode 7.1.6


Summary of changes:
 .gitignore |   5 +
 NEWS   |   9 +-
 README |   2 +-
 ada-core.el|  12 +-
 ada-indent-user-options.el |   6 +-
 ada-mode.el|   8 +-
 ada-mode.info  | 423 +
 ada-mode.texi  | 368 +++-
 ada_mode.prj   |   7 +
 build.sh   |   7 +-
 doclicense.texi| 507 +
 install.sh |   7 +-
 prj.el |  20 ++
 wisi.gpr.gp|  64 --
 14 files changed, 1033 insertions(+), 412 deletions(-)
 create mode 100644 ada_mode.prj
 create mode 100644 doclicense.texi
 create mode 100644 prj.el
 delete mode 100644 wisi.gpr.gp



[elpa] externals/ada-mode 0f4da3a 3/5: Allow compiling in elpa workspace

2021-07-30 Thread Stephen Leake
branch: externals/ada-mode
commit 0f4da3a0137497fe843b887460609c4e44d5b799
Author: Stephen Leake 
Commit: Stephen Leake 

Allow compiling in elpa workspace

* build.sh: Simplify finding WISI_DIR.

* ada_mode.prj: New file, for compiling in elpa workspace.
* prj.el:

* wisi.gpr.gp: Delete; only in packages/wisi.
---
 ada_mode.prj |  7 +++
 build.sh |  7 +--
 prj.el   | 16 +++
 wisi.gpr.gp  | 64 
 4 files changed, 24 insertions(+), 70 deletions(-)

diff --git a/ada_mode.prj b/ada_mode.prj
new file mode 100644
index 000..e02082d
--- /dev/null
+++ b/ada_mode.prj
@@ -0,0 +1,7 @@
+gpr_project_path=$WISI
+
+gpr_file=ada_mode_wisi_parse.gpr
+
+casing=ada-mode.casing
+
+-- end of file
diff --git a/build.sh b/build.sh
index be09a2a..3e0d367 100755
--- a/build.sh
+++ b/build.sh
@@ -19,12 +19,7 @@ fi
 # support for libadalang is still experimental
 gnatprep  -DHAVE_LIBADALANG="no" -DELPA="yes" -DHAVE_GNAT_UTIL=$HAVE_GNAT_UTIL 
ada_mode_wisi_parse.gpr.gp ada_mode_wisi_parse.gpr
 
-if [ -d ../wisi-3.1.? ]; then
-WISI_DIR=`ls -d ../wisi-3.1.?`
-else
-# try devel version
-WISI_DIR=`ls -d ../wisi-3.1.?.0.*`
-fi
+WISI_DIR=`ls -d ../wisi*`
 
 gnatprep -DELPA="yes" $WISI_DIR/wisi.gpr.gp $WISI_DIR/wisi.gpr
 
diff --git a/prj.el b/prj.el
new file mode 100644
index 000..9f17ac0
--- /dev/null
+++ b/prj.el
@@ -0,0 +1,16 @@
+;; Emacs wisi project definitions for compiling ada-mode in ELPA workspace
+
+(let ((wisi-core (expand-file-name "../wisi")))
+
+  (wisi-prj-select-cache
+   "ada_mode.prj"
+   (wisi-prj-default ;; for ada-build prj vars
+(create-ada-prj
+:name "ada_mode elpa"
+:compile-env
+(list
+ (concat "WISI=" wisi-core
+   "Makefile"
+   ))
+
+;; end of file
diff --git a/wisi.gpr.gp b/wisi.gpr.gp
deleted file mode 100644
index 1c17529..000
--- a/wisi.gpr.gp
+++ /dev/null
@@ -1,64 +0,0 @@
---  Abstract :
---
---  Make installed and source ELPA package wisi Ada code available for
---  other projects.
---
---  Copyright (C) 2017, 2019 Free Software Foundation, Inc.
---
---  This program is free software; you can redistribute it and/or
---  modify it under terms of the GNU General Public License as
---  published by the Free Software Foundation; either version 3, or (at
---  your option) any later version. This program is distributed in the
---  hope that it will be useful, but WITHOUT ANY WARRANTY; without even
---  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
---  PURPOSE. See the GNU General Public License for more details. You
---  should have received a copy of the GNU General Public License
---  distributed with this program; see file COPYING. If not, write to
---  the Free Software Foundation, 51 Franklin Street, Suite 500, Boston,
---  MA 02110-1335, USA.
-
-with "gnatcoll";
-with "standard_common";
-#if ELPA="no"
-with "sal";
-with "wisitoken";
-#end if;
-project Wisi is
-
-   for Source_Dirs use (".");
-
-   case Standard_Common.Profile is
-   when "On" =>
-  for Object_Dir use "obj_pro";
-  for Exec_Dir use "exec_pro";
-
-   when "Off" =>
-  for Object_Dir use "obj";
-  for Exec_Dir use ".";
-   end case;
-
-   for Languages use ("Ada", "C"); -- C needed for wisitoken-bnf-generate; 
wisitoken_grammar_re2c.c
-
-   package Compiler is
-
-  case Standard_Common.Build is
-  when "Debug" =>
- for Default_Switches ("Ada") use
-   Standard_Common.Compiler.Common_Switches &
-   Standard_Common.Compiler.Style_Checks &
-   Standard_Common.Compiler.Debug_Switches;
-
- for Default_Switches ("C") use 
Standard_Common.Compiler.Debug_Switches_C;
-
-  when "Normal" =>
- for Default_Switches ("Ada") use
-   Standard_Common.Compiler.Common_Switches &
-   Standard_Common.Compiler.Style_Checks &
-   Standard_Common.Compiler.Release_Switches;
-
- for Default_Switches ("C") use 
Standard_Common.Compiler.Release_Switches_C;
-  end case;
-
-   end Compiler;
-
-end Wisi;



[elpa] externals/wisi updated (29a0543 -> d15913f)

2021-07-30 Thread Stephen Leake
stephen_leake pushed a change to branch externals/wisi.

  from  29a0543   * NEWS: doc release
   new  da79b0f   * sal-*: Update to be compatible with gnat FSF 11, Pro 
22, Community 2021
   new  b94b59f   Fix more byte compile style warnings
   new  e199f12   Finish updating for latest GNAT
   new  d15913f   Release version 3.1.5


Summary of changes:
 .gitignore |3 +
 NEWS   |   10 +-
 README |2 +-
 doclicense.texi|  507 
 sal-gen_bounded_definite_stacks-gen_image_aux.ads  |4 +-
 sal-gen_bounded_definite_vectors-gen_image_aux.ads |4 +-
 sal-gen_bounded_definite_vectors.adb   |   20 +-
 sal-gen_bounded_definite_vectors.ads   |   31 +-
 sal-gen_definite_doubly_linked_lists.adb   |  117 +-
 sal-gen_definite_doubly_linked_lists.ads   |   13 +-
 sal-gen_definite_doubly_linked_lists_sorted.adb|   29 +-
 sal-gen_definite_doubly_linked_lists_sorted.ads|   14 +-
 sal-gen_graphs.adb |4 +-
 sal-gen_indefinite_doubly_linked_lists.adb |5 +-
 sal-gen_unbounded_definite_min_heaps_fibonacci.ads |5 +-
 sal-gen_unbounded_definite_red_black_trees.adb |  378 --
 sal-gen_unbounded_definite_red_black_trees.ads |  161 ++-
 sal-gen_unbounded_definite_stacks.adb  |   20 +-
 sal-gen_unbounded_definite_stacks.ads  |   29 +-
 ...n_unbounded_definite_vectors-gen_comparable.ads |4 +-
 sal-gen_unbounded_definite_vectors-gen_image.adb   |   16 +-
 sal-gen_unbounded_definite_vectors-gen_image.ads   |   16 +-
 ...en_unbounded_definite_vectors-gen_image_aux.adb |   96 +-
 ...en_unbounded_definite_vectors-gen_image_aux.ads |   58 +-
 sal-gen_unbounded_definite_vectors.adb |  212 ++--
 sal-gen_unbounded_definite_vectors.ads |   78 +-
 sal-gen_unbounded_definite_vectors_sorted.adb  |6 +-
 sal-gen_unbounded_definite_vectors_sorted.ads  |3 +-
 sal.adb|   40 +-
 sal.ads|6 +-
 wisi-parse-common.el   |   13 +-
 wisi-prj.el|   35 +-
 wisi.adb   |   21 +-
 wisi.el|   10 +-
 wisi.gpr.gp|4 +-
 wisi.info  | 1294 
 wisi.texi  |4 +-
 wisitoken-parse-lr-mckenzie_recover-base.adb   |8 +-
 wisitoken-parse-lr-mckenzie_recover-parse.ads  |7 +-
 wisitoken-parse-lr-parser_lists.adb|   12 +-
 wisitoken-parse-lr-parser_lists.ads|6 +-
 wisitoken-parse-lr.ads |   18 +-
 wisitoken-parse_table-mode.el  |4 +-
 wisitoken-user_guide.info  |  611 -
 wisitoken-user_guide.texinfo   |  616 ++
 wisitoken.ads  |8 +-
 46 files changed, 2126 insertions(+), 2436 deletions(-)
 create mode 100644 doclicense.texi
 delete mode 100644 wisi.info
 delete mode 100644 wisitoken-user_guide.info
 create mode 100644 wisitoken-user_guide.texinfo



[elpa] externals/wisi da79b0f 1/4: * sal-*: Update to be compatible with gnat FSF 11, Pro 22, Community 2021

2021-07-30 Thread Stephen Leake
branch: externals/wisi
commit da79b0ffca235fc09c442e7eb03f2f4cde5e1a42
Author: Stephen Leake 
Commit: Stephen Leake 

* sal-*: Update to be compatible with gnat FSF 11, Pro 22, Community 2021

* NEWS: Doc 3.1.4, 3.1.5.

* wisi-parse-common.el: Fix byte compiler style warnings.
* wisi.el:
* wisitoken-parse_table-mode.el:
---
 NEWS   |  10 +-
 sal-gen_bounded_definite_stacks-gen_image_aux.ads  |   4 +-
 sal-gen_bounded_definite_vectors-gen_image_aux.ads |   4 +-
 sal-gen_bounded_definite_vectors.adb   |  20 +-
 sal-gen_bounded_definite_vectors.ads   |  31 +-
 sal-gen_definite_doubly_linked_lists.adb   | 117 ---
 sal-gen_definite_doubly_linked_lists.ads   |  13 +-
 sal-gen_definite_doubly_linked_lists_sorted.adb|  29 +-
 sal-gen_definite_doubly_linked_lists_sorted.ads|  14 +-
 sal-gen_graphs.adb |   4 +-
 sal-gen_indefinite_doubly_linked_lists.adb |   5 +-
 sal-gen_unbounded_definite_min_heaps_fibonacci.ads |   5 +-
 sal-gen_unbounded_definite_red_black_trees.adb | 378 ++---
 sal-gen_unbounded_definite_red_black_trees.ads | 161 ++---
 sal-gen_unbounded_definite_stacks.adb  |  20 +-
 sal-gen_unbounded_definite_stacks.ads  |  29 +-
 ...n_unbounded_definite_vectors-gen_comparable.ads |   4 +-
 sal-gen_unbounded_definite_vectors-gen_image.adb   |  16 +-
 sal-gen_unbounded_definite_vectors-gen_image.ads   |  16 +-
 ...en_unbounded_definite_vectors-gen_image_aux.adb |  96 +++---
 ...en_unbounded_definite_vectors-gen_image_aux.ads |  58 ++--
 sal-gen_unbounded_definite_vectors.adb | 212 
 sal-gen_unbounded_definite_vectors.ads |  78 +++--
 sal-gen_unbounded_definite_vectors_sorted.adb  |   6 +-
 sal-gen_unbounded_definite_vectors_sorted.ads  |   3 +-
 sal.adb|  40 ++-
 sal.ads|   6 +-
 wisi-parse-common.el   |   8 +-
 wisi-prj.el|   7 +-
 wisi.el|   3 +-
 wisitoken-parse_table-mode.el  |   4 +-
 31 files changed, 926 insertions(+), 475 deletions(-)

diff --git a/NEWS b/NEWS
index 304ae9b..078a5c4 100644
--- a/NEWS
+++ b/NEWS
@@ -6,11 +6,13 @@ Please send wisi bug reports to bug-gnu-em...@gnu.org, with
 'wisi' in the subject. If possible, use M-x report-emacs-bug.
 
 
-* wisi 3.1.3
-22 Jul 2021
+* wisi 3.1.5
+29 Jul 2021
 
-** Update several SAL files for compatibility with FSF gnat 11, Pro
-   gnat 21.
+** Update several SAL files for compatibility with gnat FSF 11, Pro
+   22, Community 2021.
+
+* wisi 3.1.4 packaging error
 
 * wisi 3.1.2
 4 Jun 2020
diff --git a/sal-gen_bounded_definite_stacks-gen_image_aux.ads 
b/sal-gen_bounded_definite_stacks-gen_image_aux.ads
index e960398..2270c2a 100644
--- a/sal-gen_bounded_definite_stacks-gen_image_aux.ads
+++ b/sal-gen_bounded_definite_stacks-gen_image_aux.ads
@@ -2,7 +2,7 @@
 --
 --  Image with auxiliary data for instantiations of parent.
 --
---  Copyright (C) 2019 Free Software Foundation, Inc.
+--  Copyright (C) 2019, 2020 Free Software Foundation, Inc.
 --
 --  This library is free software;  you can redistribute it and/or modify it
 --  under terms of the  GNU General Public License  as published by the Free
@@ -18,7 +18,7 @@
 pragma License (Modified_GPL);
 
 generic
-   type Aux_Data (<>) is private;
+   type Aux_Data (<>) is limited private;
with function Element_Image (Item : in Element_Type; Aux : in Aux_Data) 
return String;
 function SAL.Gen_Bounded_Definite_Stacks.Gen_Image_Aux
   (Item  : in Stack;
diff --git a/sal-gen_bounded_definite_vectors-gen_image_aux.ads 
b/sal-gen_bounded_definite_vectors-gen_image_aux.ads
index 241e67b..a740212 100644
--- a/sal-gen_bounded_definite_vectors-gen_image_aux.ads
+++ b/sal-gen_bounded_definite_vectors-gen_image_aux.ads
@@ -2,7 +2,7 @@
 --
 --  Image with auxiliary data for instantiations of parent.
 --
---  Copyright (C) 2018 Free Software Foundation, Inc.
+--  Copyright (C) 2018, 2020 Free Software Foundation, Inc.
 --
 --  This library is free software;  you can redistribute it and/or modify it
 --  under terms of the  GNU General Public License  as published by the Free
@@ -18,6 +18,6 @@
 pragma License (Modified_GPL);
 
 generic
-   type Aux_Data (<>) is private;
+   type Aux_Data (<>) is limited private;
with function Element_Image (Item : in Element_Type; Aux : in Aux_Data) 
return String;
 function SAL.Gen_Bounded_Definite_Vectors.Gen_Image_Aux (Item : in Vector; Aux 
: in Aux_Data) return String;
diff --git a/sal-gen_bounded_definite_vectors.adb 
b/sal-gen_bounded_definite_vectors.adb
index 17aac08..b6163a6 100644
--- a/sal-gen_bounded_definite_vectors.adb
+++ b/sal-gen_bounded_definite_vectors.adb
@@ -2,7 +2,7 @@
 --
 --  See spec.

[elpa] externals/ada-mode 804cc43 4/5: * prj.el: add copyright

2021-07-30 Thread Stephen Leake
branch: externals/ada-mode
commit 804cc43cccf926ff5f28bed7a6b9150d02d2182e
Author: Stephen Leake 
Commit: Stephen Leake 

* prj.el: add copyright
---
 prj.el | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/prj.el b/prj.el
index 9f17ac0..c5f46c8 100644
--- a/prj.el
+++ b/prj.el
@@ -1,4 +1,6 @@
 ;; Emacs wisi project definitions for compiling ada-mode in ELPA workspace
+;;
+;; Copyright (C) 2021  Free Software Foundation, Inc.
 
 (let ((wisi-core (expand-file-name "../wisi")))
 



[elpa] externals/ada-mode b08975f 5/5: Release ada-mode 7.1.6

2021-07-30 Thread Stephen Leake
branch: externals/ada-mode
commit b08975f6678b5d8929fdac8864b8eb3986129996
Author: Stephen Leake 
Commit: Stephen Leake 

Release ada-mode 7.1.6

* .gitignore: More build artifacts.

* NEWS: Fix release date.

* README: Bump version.
* ada-mode.el:

* ada-mode.info: Update.

* ada-mode.texi: Bump version, fix menus.

* doclicense.texi: New file.

* install.sh (WISI_DIR): Simplify.
---
 .gitignore  |   5 +
 NEWS|   2 +-
 README  |   2 +-
 ada-mode.el |   4 +-
 ada-mode.info   | 423 ++
 ada-mode.texi   |   8 +-
 doclicense.texi | 507 
 install.sh  |   7 +-
 prj.el  |   2 +
 9 files changed, 765 insertions(+), 195 deletions(-)

diff --git a/.gitignore b/.gitignore
index b96a52b..c5c341f 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,3 +1,8 @@
 /ada-mode-pkg.el
 /ada-mode-autoloads.el
 *.elc
+ada_lr1_parse_table.txt
+*.exe
+ada_mode_wisi_parse.gpr
+check.gpr
+obj/
diff --git a/NEWS b/NEWS
index 559d61b..b35340a 100644
--- a/NEWS
+++ b/NEWS
@@ -7,7 +7,7 @@ Please send ada-mode bug reports to bug-gnu-em...@gnu.org, with
 
 
 * Ada Mode 7.1.6 
-28 Jul 2021
+30 Jul 2021
 
 ** Uses wisi 3.1.3 for compatibility with gnat FSF 11, Pro 22,
Community 2021.
diff --git a/README b/README
index f9980ca..7361dc4 100644
--- a/README
+++ b/README
@@ -1,4 +1,4 @@
-Emacs Ada mode version 7.1.5
+Emacs Ada mode version 7.1.6
 
 Ada mode provides auto-casing, fontification, navigation, and
 indentation for Ada source code files.
diff --git a/ada-mode.el b/ada-mode.el
index 7d1959c..622579c 100644
--- a/ada-mode.el
+++ b/ada-mode.el
@@ -6,8 +6,8 @@
 ;; Maintainer: Stephen Leake 
 ;; Keywords: languages
 ;;  ada
-;; Version: 7.1.5
-;; package-requires: ((uniquify-files "1.0.1") (wisi "3.1.3") (emacs "25.0"))
+;; Version: 7.1.6
+;; package-requires: ((uniquify-files "1.0.1") (wisi "3.1.3") (emacs "25.3"))
 ;; url: http://www.nongnu.org/ada-mode/
 ;;
 ;; This file is part of GNU Emacs.
diff --git a/ada-mode.info b/ada-mode.info
index b5ecdfd..e179e9f 100644
--- a/ada-mode.info
+++ b/ada-mode.info
@@ -1,7 +1,7 @@
 This is ada-mode.info, produced by makeinfo version 6.7 from
 ada-mode.texi.
 
-Copyright (C) 1999 - 2020 Free Software Foundation, Inc.
+Copyright (C) 1999 - 2021 Free Software Foundation, Inc.
 
  Permission is granted to copy, distribute and/or modify this
  document under the terms of the GNU Free Documentation License,
@@ -25,7 +25,7 @@ File: ada-mode.info,  Node: Top,  Next: Overview,  Prev: 
(dir),  Up: (dir)
 Top
 ***
 
-Ada Mode Version 7.1.3
+Ada Mode Version 7.1.5
 
 * Menu:
 
@@ -53,8 +53,8 @@ Overview
 
 Installation
 
-* Ada Reference Manual::
 * Ada executables::
+* Known versions::
 
 Ada executables
 
@@ -94,7 +94,6 @@ Developer overview
 * Directory structure::
 * ELPA::
 * Savannah::
-* ada-france::
 
 
 
@@ -159,9 +158,9 @@ File: ada-mode.info,  Node: Installation,  Next: 
Customization,  Prev: Overview,
 2 Installation
 **
 
-Ada mode requires Emacs 25.0 or greater.  Compiling the Ada code for the
+Ada mode requires Emacs 25.3 or greater.  Compiling the Ada code for the
 external process parser requires GNAT GPL 2017 or later; tested with
-GNAT Community Edition 2019 and GNAT Pro 19.
+GNAT Community Edition 2021 and GNAT Pro 22.2 (*note Known versions::).
 
Ada mode is distributed in the Gnu ELPA package archive; it can be
 installed via 'M-x list-packages' (*note (emacs)Packages::).  Note that
@@ -176,26 +175,18 @@ _after_ customizing 'Info-default-directory-list' (if you 
do that):
 ada-mode-version'.
 
You must also install the associated Ada executables (for the
-language parser).  You may want to install the Ada Reference Manual.
+language parser).  You may want to install the Ada Reference Manual in
+info format, via the ELPA package ada-ref-man.
 
 * Menu:
 
-* Ada Reference Manual::
 * Ada executables::
+* Known versions::
 
 
-File: ada-mode.info,  Node: Ada Reference Manual,  Next: Ada executables,  Up: 
Installation
+File: ada-mode.info,  Node: Ada executables,  Next: Known versions,  Up: 
Installation
 
-2.1 Ada Reference Manual
-
-
-The ELPA package ada-ref-man includes the Ada Reference Manual and
-Annotated Ada Reference Manual in info format.
-
-
-File: ada-mode.info,  Node: Ada executables,  Prev: Ada Reference Manual,  Up: 
Installation
-
-2.2 Ada executables
+2.1 Ada executables
 ===
 
 Ada mode requires the external parser, which must be compiled.
@@ -215,10 +206,19 @@ supports additional queries.
 
Both the parser and 'gpr_query' require the 'GNATCOLL' library
 provided by AdaCore, distributed with GNAT GPL 2017 or later, and also
-available at Github ().  The notes
-below assume that the compiler is installed at '$prefix', e.g.
-'/usr/local/gnat-2019', and that '$prefix

[elpa] externals/wisi d15913f 4/4: Release version 3.1.5

2021-07-30 Thread Stephen Leake
branch: externals/wisi
commit d15913f4fd6a5bc545c2a656645b44fc123c4979
Author: Stephen Leake 
Commit: Stephen Leake 

Release version 3.1.5

* .gitignore: More build artifacts.

* NEWS: Fix release date.

* doclicense.texi: New file.

* wisi.info: Delete; elpa builds it, so no longer in git.

* README: Bump version.
* wisi.el:
* wisi.texi:

* wisitoken-user_guide.texinfo: New file.
---
 .gitignore   |3 +
 NEWS |2 +-
 README   |2 +-
 doclicense.texi  |  507 +
 wisi.el  |4 +-
 wisi.info| 1294 --
 wisi.texi|4 +-
 wisitoken-user_guide.info|  611 
 wisitoken-user_guide.texinfo |  616 
 9 files changed, 1132 insertions(+), 1911 deletions(-)

diff --git a/.gitignore b/.gitignore
index 5f08039..cb87271 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,3 +1,6 @@
 /wisi-pkg.el
 /wisi-autoloads.el
 *.elc
+obj/
+wisi.gpr
+wisitoken-user_guide.info
diff --git a/NEWS b/NEWS
index 952e6c7..9264d77 100644
--- a/NEWS
+++ b/NEWS
@@ -7,7 +7,7 @@ Please send wisi bug reports to bug-gnu-em...@gnu.org, with
 
 
 * wisi 3.1.5
-29 Jul 2021
+30 Jul 2021
 
 ** Update several SAL files for compatibility with gnat FSF 11, Pro
22, Community 2021.
diff --git a/README b/README
index 7e3ef01..6132ef2 100644
--- a/README
+++ b/README
@@ -1,4 +1,4 @@
-Emacs wisi package 3.1.3
+Emacs wisi package 3.1.5
 
 The wisi package provides utilities for using generalized
 error-correcting LR parsers (in external processes) to do indentation,
diff --git a/doclicense.texi b/doclicense.texi
new file mode 100644
index 000..a511ffc
--- /dev/null
+++ b/doclicense.texi
@@ -0,0 +1,507 @@
+@c -*-texinfo-*-
+@c The GNU Free Documentation License.
+@center Version 1.3, 3 November 2008
+
+@c This file is intended to be included within another document,
+@c hence no sectioning command or @node.
+
+@display
+Copyright @copyright{} 2000, 2001, 2002, 2007, 2008, 2009 Free Software 
Foundation, Inc.
+@uref{http://fsf.org/}
+
+Everyone is permitted to copy and distribute verbatim copies
+of this license document, but changing it is not allowed.
+@end display
+
+@enumerate 0
+@item
+PREAMBLE
+
+The purpose of this License is to make a manual, textbook, or other
+functional and useful document @dfn{free} in the sense of freedom: to
+assure everyone the effective freedom to copy and redistribute it,
+with or without modifying it, either commercially or noncommercially.
+Secondarily, this License preserves for the author and publisher a way
+to get credit for their work, while not being considered responsible
+for modifications made by others.
+
+This License is a kind of ``copyleft'', which means that derivative
+works of the document must themselves be free in the same sense.  It
+complements the GNU General Public License, which is a copyleft
+license designed for free software.
+
+We have designed this License in order to use it for manuals for free
+software, because free software needs free documentation: a free
+program should come with manuals providing the same freedoms that the
+software does.  But this License is not limited to software manuals;
+it can be used for any textual work, regardless of subject matter or
+whether it is published as a printed book.  We recommend this License
+principally for works whose purpose is instruction or reference.
+
+@item
+APPLICABILITY AND DEFINITIONS
+
+This License applies to any manual or other work, in any medium, that
+contains a notice placed by the copyright holder saying it can be
+distributed under the terms of this License.  Such a notice grants a
+world-wide, royalty-free license, unlimited in duration, to use that
+work under the conditions stated herein.  The ``Document'', below,
+refers to any such manual or work.  Any member of the public is a
+licensee, and is addressed as ``you''.  You accept the license if you
+copy, modify or distribute the work in a way requiring permission
+under copyright law.
+
+A ``Modified Version'' of the Document means any work containing the
+Document or a portion of it, either copied verbatim, or with
+modifications and/or translated into another language.
+
+A ``Secondary Section'' is a named appendix or a front-matter section
+of the Document that deals exclusively with the relationship of the
+publishers or authors of the Document to the Document's overall
+subject (or to related matters) and contains nothing that could fall
+directly within that overall subject.  (Thus, if the Document is in
+part a textbook of mathematics, a Secondary Section may not explain
+any mathematics.)  The relationship could be a matter of historical
+connection with the subject or with related matters, or of legal,
+commercial, philosophical, ethical or political position regarding
+th

[elpa] externals/wisi e199f12 3/4: Finish updating for latest GNAT

2021-07-30 Thread Stephen Leake
branch: externals/wisi
commit e199f1238510210865c1fb0b321feefec3a8e373
Author: Stephen Leake 
Commit: Stephen Leake 

Finish updating for latest GNAT

* wisi.gpr.gp: Add -gnat2020.

* wisi.adb: Match sal-* changes.
* wisitoken-parse-lr-mckenzie_recover-base.adb:
* wisitoken-parse-lr-mckenzie_recover-parse.ads:
* wisitoken-parse-lr-parser_lists.adb:
* wisitoken-parse-lr-parser_lists.ads:
* wisitoken-parse-lr.ads:
* wisitoken.ads:
---
 wisi.adb  | 21 +
 wisi.gpr.gp   |  4 ++--
 wisitoken-parse-lr-mckenzie_recover-base.adb  |  8 +++-
 wisitoken-parse-lr-mckenzie_recover-parse.ads |  7 ---
 wisitoken-parse-lr-parser_lists.adb   | 12 ++--
 wisitoken-parse-lr-parser_lists.ads   |  6 +++---
 wisitoken-parse-lr.ads| 18 +-
 wisitoken.ads |  8 ++--
 8 files changed, 50 insertions(+), 34 deletions(-)

diff --git a/wisi.adb b/wisi.adb
index 91dacab..b874532 100644
--- a/wisi.adb
+++ b/wisi.adb
@@ -2,7 +2,7 @@
 --
 --  See spec.
 --
---  Copyright (C) 2017 - 2020 Free Software Foundation, Inc.
+--  Copyright (C) 2017 - 2021 Free Software Foundation, Inc.
 --
 --  This library is free software;  you can redistribute it and/or modify it
 --  under terms of the  GNU General Public License  as published by the Free
@@ -1577,18 +1577,21 @@ package body Wisi is
  Cache : Face_Cache_Type renames Data.Face_Caches 
(Cache_Cur);
  Other_Cur : Cursor := Find_In_Range
(Iter, Ascending, Cache.Char_Region.Last + 1, 
Token.Char_Region.Last);
- Temp : Cursor;
+ To_Delete : Buffer_Pos_Lists.List;
   begin
  loop
 exit when not Has_Element (Other_Cur) or else
   Data.Face_Caches (Other_Cur).Char_Region.First > 
Token.Char_Region.Last;
-Temp := Other_Cur;
+To_Delete.Append (Data.Face_Caches 
(Other_Cur).Char_Region.First);
 Other_Cur := Next (Iter, Other_Cur);
-Delete (Data.Face_Caches, Temp);
  end loop;
 
  Cache.Class:= Param.Class;
  Cache.Char_Region.Last := Token.Char_Region.Last;
+
+ for Face of To_Delete loop
+Data.Face_Caches.Delete (Face);
+ end loop;
   end;
else
   Data.Face_Caches.Insert ((Token.Char_Region, Param.Class, 
(Set => False)));
@@ -1610,20 +1613,22 @@ package body Wisi is
 
   Iter  : constant Iterator := Data.Face_Caches.Iterate;
   Cache_Cur : Cursor;
-  Temp  : Cursor;
begin
   for I of Params loop
  if Tree.Byte_Region (Tokens (I)) /= Null_Buffer_Region then
 declare
-   Token : Aug_Token_Const_Ref renames Get_Aug_Token_Const_1 
(Tree, Tokens (I));
+   Token : Aug_Token_Const_Ref renames Get_Aug_Token_Const_1 
(Tree, Tokens (I));
+   To_Delete : Buffer_Pos_Lists.List;
 begin
Cache_Cur := Find_In_Range (Iter, Ascending, 
Token.Char_Region.First, Token.Char_Region.Last);
loop
   exit when not Has_Element (Cache_Cur) or else
 Data.Face_Caches (Cache_Cur).Char_Region.First > 
Token.Char_Region.Last;
-  Temp := Cache_Cur;
+  To_Delete.Append (Data.Face_Caches 
(Cache_Cur).Char_Region.First);
   Cache_Cur := Next (Iter, Cache_Cur);
-  Delete (Data.Face_Caches, Temp);
+   end loop;
+   for Face of To_Delete loop
+  Data.Face_Caches.Delete (Face);
end loop;
 end;
  end if;
diff --git a/wisi.gpr.gp b/wisi.gpr.gp
index 1c17529..54c9239 100644
--- a/wisi.gpr.gp
+++ b/wisi.gpr.gp
@@ -46,7 +46,7 @@ project Wisi is
  for Default_Switches ("Ada") use
Standard_Common.Compiler.Common_Switches &
Standard_Common.Compiler.Style_Checks &
-   Standard_Common.Compiler.Debug_Switches;
+   Standard_Common.Compiler.Debug_Switches & "-gnat2020";
 
  for Default_Switches ("C") use 
Standard_Common.Compiler.Debug_Switches_C;
 
@@ -54,7 +54,7 @@ project Wisi is
  for Default_Switches ("Ada") use
Standard_Common.Compiler.Common_Switches &
Standard_Common.Compiler.Style_Checks &
-   Standard_Common.Compiler.Release_Switches;
+   Standard_Common.Compiler.Release_Switches & "-gnat2020";
 
  for Default_Switches ("C") use 
Standard_Common.Compiler.Release_Switches_C;
   end case;
diff --git a/wisitoken-parse-lr-mckenzie_recover-base.

[elpa] externals/ada-mode 565a08d 1/5: Minor fixes preparing for 7.1.6 release

2021-07-30 Thread Stephen Leake
branch: externals/ada-mode
commit 565a08dec71c38306ff496f68b87c7275cedf2d9
Author: Stephen Leake 
Commit: Stephen Leake 

Minor fixes preparing for 7.1.6 release

* NEWS: Doc 7.1.6.

* ada-core.el (ada-prj-select-compiler): Fix byte-compiler style warnings.
* ada-indent-user-options.el (ada-indent-label):
* ada-mode.el:

* ada-mode.texi: Clean up, improve.
---
 NEWS   |   9 +-
 ada-core.el|  10 +-
 ada-indent-user-options.el |   3 +-
 ada-mode.el|   2 +-
 ada-mode.texi  | 362 -
 5 files changed, 241 insertions(+), 145 deletions(-)

diff --git a/NEWS b/NEWS
index e0f29b3..559d61b 100644
--- a/NEWS
+++ b/NEWS
@@ -6,10 +6,13 @@ 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.1.5
-22 Jul 2021
+* Ada Mode 7.1.6 
+28 Jul 2021
 
-** Uses wisi 3.1.3 for compatibility with FSF gnat 11, Pro gnat 21.
+** Uses wisi 3.1.3 for compatibility with gnat FSF 11, Pro 22,
+   Community 2021.
+
+* Ada Mode 7.1.5 packaging bug
 
 * Ada Mode 7.1.4
 07 Aug 2020
diff --git a/ada-core.el b/ada-core.el
index 85c1787..c0aac0a 100644
--- a/ada-core.el
+++ b/ada-core.el
@@ -1,6 +1,6 @@
 ;;; ada-core.el --- core facilities for ada-mode -*- lexical-binding:t -*-
 
-;; Copyright (C) 1994, 1995, 1997 - 2017, 2019 - 2020  Free Software 
Foundation, Inc.
+;; Copyright (C) 1994, 1995, 1997 - 2017, 2019 - 2021  Free Software 
Foundation, Inc.
 ;;
 ;; Author: Stephen Leake 
 ;; Maintainer: Stephen Leake 
@@ -190,9 +190,15 @@ is the package spec.")
 (defconst ada-refactor-format-paramlist 5)
 
 (defun ada-refactor (action)
+  "Perform refactor action ACTION on symbol at point."
   (wisi-validate-cache (line-end-position -7) (line-end-position 7) t 
'navigate)
   (save-excursion
+;; We include punctuation and quote for operators.
 (skip-syntax-backward "w_.\"")
+
+;; Skip leading punctuation, for "-Foo.Bar".
+(skip-syntax-forward ".")
+
 (let* ((edit-begin (point))
   (cache (wisi-goto-statement-start))
   (parse-begin (point))
@@ -712,7 +718,7 @@ Deselects the current project first."
 (make-obsolete 'ada-select-prj-file 'wisi-prj-select-cache "ada-mode 7.0")
 
 (cl-defgeneric ada-prj-select-compiler (compiler project)
-  "PROJECT has been selected; set any project options that are both Ada and 
compiler specific.")
+  "Set PROJECT options that are Ada and compiler specific.")
 
 (cl-defgeneric ada-prj-deselect-compiler (compiler project)
   "PROJECT has been deselected; unset any project options that are both Ada 
and compiler specific.")
diff --git a/ada-indent-user-options.el b/ada-indent-user-options.el
index 0169d00..76a417e 100644
--- a/ada-indent-user-options.el
+++ b/ada-indent-user-options.el
@@ -70,7 +70,8 @@ Otherwise, they are indented as previous comments or code."
 (make-variable-buffer-local 'ada-indent-comment-gnat)
 
 (defcustom ada-indent-label -3
-  "Indentation for a loop, block, or statement label, relative to the item it 
labels.
+  "Indentation for a loop, block, or statement label,
+relative to the item it labels.
 
 Example :
Label_1 :
diff --git a/ada-mode.el b/ada-mode.el
index 576ebbf..d3c1c2b 100644
--- a/ada-mode.el
+++ b/ada-mode.el
@@ -144,7 +144,7 @@ rather than to the same column."
   :safe #'booleanp)
 
 (defcustom ada-which-func-parse-size 3
-  "Minimum size of the region surrounding point that is parsed for 
`which-function-mode'."
+  "Minimum size of region around point parsed for `which-function-mode'."
   :group 'ada
   :type 'integer
   :safe #'integerp)
diff --git a/ada-mode.texi b/ada-mode.texi
index 982a0b2..35610be 100644
--- a/ada-mode.texi
+++ b/ada-mode.texi
@@ -107,7 +107,6 @@ Developer overview
 * Directory structure::
 * ELPA::
 * Savannah::
-* ada-france::
 
 @end detailmenu
 @end menu
@@ -166,9 +165,10 @@ supports LSP.
 @node Installation, Customization, Overview, Top
 @chapter Installation
 
-Ada mode requires Emacs 25.0 or greater. Compiling the Ada code for
+Ada mode requires Emacs 25.3 or greater. Compiling the Ada code for
 the external process parser requires GNAT GPL 2017 or later; tested
-with GNAT Community Edition 2019 and GNAT Pro 19.
+with GNAT Community Edition 2021 and GNAT Pro 22.2 (@pxref{Known
+versions}).
 
 Ada mode is distributed in the Gnu ELPA package archive; it can be
 installed via @code{M-x list-packages} (@pxref{Packages,,,emacs,Emacs
@@ -187,18 +187,14 @@ To see what version of Ada mode you have installed, 
invoke @kbd{M-x
 ada-mode-version}.
 
 You must also install the associated Ada executables (for the language
-parser). You may want to install the Ada Reference Manual.
+parser). You may want to install the Ada Reference Manual in info
+format, via the ELPA package ada-ref-man.
 
 @menu
-* Ada Reference Manual::
 * Ada executables::
+* Known versions
 @end menu
 
-@node Ada Ref

[elpa] externals/ada-mode f257b28 2/5: Fix more byte-compiler style warnings

2021-07-30 Thread Stephen Leake
branch: externals/ada-mode
commit f257b2849fc85e0870c9fb11c02589d09bdcbdbd
Author: Stephen Leake 
Commit: Stephen Leake 

Fix more byte-compiler style warnings

* ada-core.el: More byte-compiler style warnings.
* ada-indent-user-options.el:
* ada-mode.el (ada-mode):
---
 ada-core.el| 2 +-
 ada-indent-user-options.el | 3 ++-
 ada-mode.el| 2 --
 3 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/ada-core.el b/ada-core.el
index c0aac0a..074ab2c 100644
--- a/ada-core.el
+++ b/ada-core.el
@@ -721,7 +721,7 @@ Deselects the current project first."
   "Set PROJECT options that are Ada and compiler specific.")
 
 (cl-defgeneric ada-prj-deselect-compiler (compiler project)
-  "PROJECT has been deselected; unset any project options that are both Ada 
and compiler specific.")
+  "Unset any PROJECT options that are both Ada and compiler specific.")
 
 (cl-defmethod wisi-prj-select :after ((project ada-prj))
   (ada-prj-select-compiler (ada-prj-compiler project) project))
diff --git a/ada-indent-user-options.el b/ada-indent-user-options.el
index 76a417e..479b4b2 100644
--- a/ada-indent-user-options.el
+++ b/ada-indent-user-options.el
@@ -171,7 +171,8 @@ An example is:
 
 (defcustom ada-indent-hanging-rel-exp nil
   "If nil, indent hanging lines in an expression relative to the first line.
-Otherwise, indent by `ada-indent-broken' relative to the start of the 
expression."
+Otherwise, indent by `ada-indent-broken' relative to the start of
+the expression."
   :type 'boolean
   :safe #'booleanp)
 (make-variable-buffer-local 'ada-indent-hanging-rel-exp)
diff --git a/ada-mode.el b/ada-mode.el
index d3c1c2b..7d1959c 100644
--- a/ada-mode.el
+++ b/ada-mode.el
@@ -1602,8 +1602,6 @@ Prompts with completion, defaults to filename at point."
 
   (setq align-mode-rules-list ada-align-rules)
 
-  (easy-menu-add ada-mode-menu ada-mode-map)
-
   (wisi-setup
:indent-calculate '(ada-wisi-comment)
:post-indent-fail 'ada-wisi-post-parse-fail



[elpa] externals/wisi b94b59f 2/4: Fix more byte compile style warnings

2021-07-30 Thread Stephen Leake
branch: externals/wisi
commit b94b59f18696b81fa2deba6ba95f6602f9faa143
Author: Stephen Leake 
Commit: Stephen Leake 

Fix more byte compile style warnings

* wisi-parse-common.el: Fix more byte compile style warnings.
* wisi-prj.el:
* wisi.el:
---
 NEWS |  2 +-
 wisi-parse-common.el |  5 +
 wisi-prj.el  | 28 
 wisi.el  |  3 ++-
 4 files changed, 20 insertions(+), 18 deletions(-)

diff --git a/NEWS b/NEWS
index 078a5c4..952e6c7 100644
--- a/NEWS
+++ b/NEWS
@@ -12,7 +12,7 @@ Please send wisi bug reports to bug-gnu-em...@gnu.org, with
 ** Update several SAL files for compatibility with gnat FSF 11, Pro
22, Community 2021.
 
-* wisi 3.1.4 packaging error
+* wisi 3.1.3, 3.1.4 packaging error
 
 * wisi 3.1.2
 4 Jun 2020
diff --git a/wisi-parse-common.el b/wisi-parse-common.el
index 01a417b..4e71be9 100644
--- a/wisi-parse-common.el
+++ b/wisi-parse-common.el
@@ -304,9 +304,6 @@ Larger stack size allows more deeply nested constructs.")
 Otherwise, they are indented with previous comments or code.
 Normally set from a language-specific option.")
 
-(defvar-local wisi-end-caches nil
-  "List of buffer positions of caches in current statement that need 
wisi-cache-end set.")
-
 (defconst wisi-eoi-term 'Wisi_EOI
   ;; must match FastToken wisi-output_elisp.adb EOI_Name, which must
   ;; be part of a valid Ada identifer.
@@ -319,7 +316,7 @@ Normally set from a language-specific option.")
statement-start
misc ;; other stuff
]
-  "array of valid token classes; checked in wisi-statement-action, used in 
wisi-process-parse.")
+  "array of valid token classes.")
 
 (defun wisi-error-msg (message &rest args)
   (let ((line (line-number-at-pos))
diff --git a/wisi-prj.el b/wisi-prj.el
index 8bbb5ca..015fe1e 100644
--- a/wisi-prj.el
+++ b/wisi-prj.el
@@ -197,18 +197,20 @@ and line number.
 COLUMN).")
 
 (cl-defgeneric wisi-xref-completion-delim-regex (xref)
-  "Return the value for `completion-pcm--delim-wild-regex' to be used with 
`wisi-xref-completion-table'.")
+  "Return the value for `completion-pcm--delim-wild-regex'
+to be used with `wisi-xref-completion-table'.")
 
 (cl-defgeneric wisi-xref-completion-regexp (xref)
-  "Return a regular expression matching the result of completing with 
`wisi-xref-completion-table'.
-Group 1 must be the simple symbol; the rest of the item may be annotations.")
+  "Regular expression matching completion with `wisi-xref-completion-table'.
+Group 1 must be the simple symbol; the rest of the item may be
+annotations.")
 
 (cl-defgeneric wisi-xref-completion-at-point-table (xref project)
-  "Return a completion table of names defined in PROJECT, for 
`completion-at-point'.
+  "Return a completion table of names defined in PROJECT.
 The table is a simple list of symbols.")
 
 (cl-defgeneric wisi-xref-definitions (xref project item)
-  "Return all definitions (classwide) of ITEM (an xref-item), as a list of 
xref-items.")
+  "All definitions of ITEM (an xref-item), as a list of xref-items.")
 
 (cl-defgeneric wisi-xref-references (xref project item)
   "Return all references to ITEM (an xref-item), as a list of xref-items.")
@@ -428,7 +430,8 @@ FILENAME - absolute filename containing the identifier
 LINE - line number containing the identifier
 COLUMN - Emacs column of the start of the identifier
 
-Displays a buffer in compilation-mode giving locations of the parent type 
declarations.")
+Displays a buffer in compilation-mode giving locations of the
+parent type declarations.")
 
 (defun wisi-show-declaration-parents ()
   "Display the locations of the parent type declarations of the type 
identifier around point."
@@ -492,7 +495,7 @@ With prefix, keep previous references in output buffer."
 ))
 
 (cl-defgeneric wisi-xref-overriding (xref project &key identifier filename 
line column)
-  "Displays a buffer in compilation-mode giving locations of the overriding 
declarations.
+  "Displays a buffer giving locations of the overriding declarations.
 XREF- dispatching object.
 PROJECT - a `wisi-prj' object.
 IDENTIFIER - an identifier or operator_symbol
@@ -515,7 +518,7 @@ COLUMN - Emacs column of the start of the identifier ")
 ))
 
 (cl-defgeneric wisi-xref-overridden (xref project &key identifier filename 
line column)
-  "Returns a list (FILE LINE COLUMN) giving the location of the overridden 
declaration.
+  "Returns the location of the overridden declaration as (FILE LINE COLUMN).
 XREF- dispatching object.
 PROJECT - a `wisi-prj' object.
 IDENTIFIER - an identifier or operator_symbol
@@ -544,9 +547,9 @@ COLUMN - Emacs column of the start of the identifier")
 
  wisi-prj specific methods
 
-(cl-defmethod project-roots ((_project wisi-prj))
-  ;; Not meaningful
-  nil)
+(cl-defmethod project-root ((project wisi-prj))
+   ;; Not meaningful, but some project functions insist on a valid directory
+   (car (wisi-prj-source-path project)))
 
 (cl-defmethod project-files ((pro

[elpa] elpa-admin 069c128: Allow testing locally via list-packages

2021-07-30 Thread Stephen Leake
branch: elpa-admin
commit 069c128aea984b2f98567a5dcef82bee71f46e69
Author: Stephen Leake 
Commit: Stephen Leake 

Allow testing locally via list-packages

* elpa-admin.el (elpaa--make-one-tarball): Add no-symlink arg.
(elpaa-batch-make-one-devel): New.
(elpaa-batch-make-one-info): New.
(elpaa--make-one-package): Add devel-only arg.
---
 elpa-admin.el | 33 ++---
 1 file changed, 26 insertions(+), 7 deletions(-)

diff --git a/elpa-admin.el b/elpa-admin.el
index 50ee89f..e26108b 100644
--- a/elpa-admin.el
+++ b/elpa-admin.el
@@ -489,7 +489,7 @@ Do it without leaving the current branch."
   oldtarballs)
 
 (defun elpaa--make-one-tarball ( tarball dir pkg-spec metadata
- &optional revision-function one-tarball)
+ &optional revision-function one-tarball 
no-symlink)
   "Create file TARBALL for PKGNAME if not done yet.
 Return non-nil if a new tarball was created."
   (elpaa--message "Building tarball %s..." tarball)
@@ -567,9 +567,10 @@ Return non-nil if a new tarball was created."
 (elpaa--call nil "git" "tag" "-f"
  (format "%s-release/%s-%s"
  elpaa--name pkgname vers
-(let ((link (expand-file-name (format "%s.tar" pkgname) destdir)))
-  (when (file-symlink-p link) (delete-file link))
-  (make-symbolic-link (file-name-nondirectory tarball) link))
+   (unless no-symlink
+  (let ((link (expand-file-name (format "%s.tar" pkgname) 
destdir)))
+   (when (file-symlink-p link) (delete-file link))
+   (make-symbolic-link (file-name-nondirectory tarball) link)))
 (setq oldtarballs
   (elpaa--prune-old-tarballs tarball oldtarballs destdir
  ;; Keep release versions at
@@ -639,6 +640,23 @@ Return non-nil if a new tarball was created."
 (elpaa--make-one-package (elpaa--get-package-spec
 (pop command-line-args-left)
 
+(defun elpaa-batch-make-one-devel (&rest _)
+  "Build the new devel tarball (if needed) for packages listed on command 
line."
+  (while command-line-args-left
+(let* ((pkgname (pop command-line-args-left))
+  (pkg-spec (elpaa--get-package-spec pkgname))
+  (elpaa--sandbox (not (eq system-type 'windows-nt
+  (elpaa--make-one-package pkg-spec nil t
+
+(defun elpaa-batch-make-one-info (&rest _)
+  "Build the info files for packages listed on command line."
+  (while command-line-args-left
+(let* ((pkgname (pop command-line-args-left))
+  (pkg-spec (elpaa--get-package-spec pkgname))
+  (dir (expand-file-name pkgname "packages"))
+  (elpaa--sandbox (not (eq system-type 'windows-nt
+  (elpaa--build-Info pkg-spec dir
+
 (defun elpaa-batch-make-one-tarball (&rest _)
   "Build a tarball for a particular package."
   (while command-line-args-left
@@ -749,10 +767,11 @@ Return non-nil if a new tarball was created."
contents))
 (write-region (point-min) (point-max) file)
 
-(defun elpaa--make-one-package (pkg-spec &optional one-tarball)
+(defun elpaa--make-one-package (pkg-spec &optional one-tarball devel-only)
   "Build the new tarballs (if needed) for PKG-SPEC.
 If ONE-TARBALL is non-nil, don't try and select some other revision and
-place the resulting tarball into the file named ONE-TARBALL."
+place the resulting tarball into the file named ONE-TARBALL.
+If DEVEL-ONLY is non-nil, only build the devel tarball."
   (elpaa--message "Checking package %s for updates..." (car pkg-spec))
   (let* ((pkgname (car pkg-spec))
  (dir (expand-file-name pkgname "packages"))
@@ -791,7 +810,7 @@ place the resulting tarball into the file named 
ONE-TARBALL."
  dir pkg-spec
  `(nil ,devel-vers
. ,(nthcdr 2 metadata))
- nil one-tarball
+ nil one-tarball devel-only
 
 ;; Try and build the latest release tarball.
 (cond



[elpa] main 638a94c: * elpa-packages ("ada-mode"): Add :doc

2021-07-30 Thread Stephen Leake
branch: main
commit 638a94cbaf1ab14b66daccf21a75318a89b141e5
Author: Stephen Leake 
Commit: Stephen Leake 

* elpa-packages ("ada-mode"): Add :doc
---
 elpa-packages | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/elpa-packages b/elpa-packages
index af7f075..1d92d27 100644
--- a/elpa-packages
+++ b/elpa-packages
@@ -33,7 +33,7 @@
 
 (("ace-window" :url "https://github.com/abo-abo/ace-window";)
  ("ack":url "https://github.com/leoliu/ack-el";)
- ("ada-mode"   :url nil)
+ ("ada-mode"   :url nil :doc ("ada-mode.texi" "gpr-mode.texi"))
  ("ada-ref-man":url nil)
  ("adaptive-wrap"  :url nil)
  ("adjust-parens"  :url nil)
@@ -402,7 +402,7 @@
  ("websocket"  :url "https://github.com/ahyatt/emacs-websocket.git";)
  ("windower"   :url "https://gitlab.com/ambrevar/emacs-windower";)
  ("windresize" :url nil)
- ("wisi"   :url nil)
+ ("wisi"   :url nil :doc ("wisi.texi" 
"wisitoken-user_guide.texinfo"))
  ("wisitoken-grammar-mode" :url nil)
  ("which-key"   :url "https://github.com/justbur/emacs-which-key";
   :auto-sync t)