Skip to content

Commit

Permalink
Fix a "Bad bounding indices" error on my system
Browse files Browse the repository at this point in the history
  • Loading branch information
gasche committed Oct 3, 2023
1 parent e7aad1d commit 11c1a5f
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions coq/coq-system.el
Original file line number Diff line number Diff line change
Expand Up @@ -550,13 +550,14 @@ alreadyopen is t if buffer already existed."
(defun coq--read-one-option-from-project-file (switch arity raw-args)
"Cons SWITCH with ARITY arguments from RAW-ARGS.
If ARITY is nil, return SWITCH."
(if arity
(let ((arguments
(condition-case-unless-debug nil
(cl-subseq raw-args 0 arity)
(warn "Invalid _CoqProject: not enough arguments for %S" switch))))
(cons switch arguments))
switch))
(cond
((not arity) switch)
((< (length raw-args) arity)
(warn "Invalid _CoqProject: not enough arguments for %S" switch)
switch)
(t
(let ((arguments (cl-subseq raw-args 0 arity)))
(cons switch arguments)))))

(defun coq--read-options-from-project-file (contents)
"Read options from CONTENTS of _CoqProject.
Expand Down

0 comments on commit 11c1a5f

Please sign in to comment.