Function: opascal-is-use-clause-end

opascal-is-use-clause-end is a byte-compiled function defined in opascal.el.gz.

Signature

(opascal-is-use-clause-end AT-TOKEN LAST-TOKEN LAST-COLON FROM-KIND)

Source Code

;; Defined in /usr/src/emacs/lisp/progmodes/opascal.el.gz
(defun opascal-is-use-clause-end (at-token last-token last-colon from-kind)
  ;; True if we are after the end of a uses type clause.
  (when (and last-token
             (not last-colon)
             (eq 'comma (opascal-token-kind at-token))
             (eq 'semicolon from-kind))
    ;; Scan for the uses statement, just to be sure.
    (let ((token at-token))
      (catch 'done
        (opascal--scan-non-whitespace-backward token nil
          ((opascal--in opascal-use-clauses)
           (throw 'done t))

          ;; Identifiers, strings, "in" keyword, and commas
          ;; are allowed in use clauses.
          ((or 'word 'comma 'in  'string 'double-quoted-string))

          ;; Nothing else is.
          (_ (throw 'done nil)))
        nil))))