[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/dart-mode bd08208 082/192: Switch completely to cl-lib (#3
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/dart-mode bd08208 082/192: Switch completely to cl-lib (#33) |
Date: |
Sun, 29 Aug 2021 11:01:55 -0400 (EDT) |
branch: elpa/dart-mode
commit bd0820825f78e805d498dcb4ecdec0783be57f94
Author: Philipp Stephani <p.stephani2+github@gmail.com>
Commit: Natalie Weizenbaum <nweiz@google.com>
Switch completely to cl-lib (#33)
Remove compatibility code that would load cl, and switch all remaining
macros to cl-lib. dart-mode already requires cl-lib, and its Flycheck
dependency even requires Emacs 24.3, where cl-lib is built-in.
---
dart-mode.el | 31 ++++++++-----------------------
1 file changed, 8 insertions(+), 23 deletions(-)
diff --git a/dart-mode.el b/dart-mode.el
index 07bc3da..ab9cc07 100644
--- a/dart-mode.el
+++ b/dart-mode.el
@@ -46,26 +46,11 @@
(eval-and-compile (c-add-language 'dart-mode 'java-mode))
+(require 'cl-lib)
(require 'dash)
(require 'flycheck)
(require 'json)
-;; See https://debbugs.gnu.org/cgi/bugreport.cgi?bug=18845. cc-mode before 24.4
-;; uses 'cl without requiring it but we use 'cl-lib in this package. We can
-;; simply require 'cl past 24.4 but need to work around the dependency for
-;; earlier versions.
-(eval-when-compile
- (unless (require 'cl-lib nil t)
- (require 'cl)))
-
-(eval-and-compile
- (if (version<= "24.4" emacs-version)
- (require 'cl)))
-
-(if (version< emacs-version "24.3")
- (unless (fboundp 'cl-set-difference)
- (defalias 'cl-set-difference 'set-difference)))
-
;;; CC configuration
(c-lang-defconst c-symbol-start
@@ -249,10 +234,10 @@
When indenting inline functions, we want to pretend that
functions taking them as parameters essentially don't exist."
- (destructuring-bind (syntax . anchor) info
+ (cl-destructuring-bind (syntax . anchor) info
(let ((arglist-count
- (loop for (symbol . _) in c-syntactic-context
- count (eq symbol 'arglist-cont-nonempty))))
+ (cl-loop for (symbol . _) in c-syntactic-context
+ count (eq symbol 'arglist-cont-nonempty))))
(if (> arglist-count 0)
(- (* -1 c-basic-offset arglist-count)
(if (eq syntax 'block-close) c-basic-offset 0))
@@ -261,7 +246,7 @@ functions taking them as parameters essentially don't
exist."
(defun dart-brace-list-cont-nonempty-offset (info)
"Indent a brace-list line in the same style as arglist-cont-nonempty.
This could be either an actual brace-list or an optional parameter."
- (destructuring-bind (_ . anchor) info
+ (cl-destructuring-bind (_ . anchor) info
;; If we're in a function definition with optional arguments, indent as if
;; the brace wasn't there. Currently this misses the in-function function
;; definition, but that's probably acceptable.
@@ -331,7 +316,7 @@ SYNTAX-GUESS is the output of `c-guess-basic-syntax'."
(backward-up-list)
(when (= (char-after) ?\[)
(setq ad-return-value
- `((,(case type
+ `((,(cl-case type
(arglist-intro 'brace-list-intro)
(arglist-cont 'brace-list-entry)
(arglist-cont-nonempty
'dart-brace-list-cont-nonempty)
@@ -831,10 +816,10 @@ true for positions before the start of the statement, but
on its line."
(save-excursion
(skip-syntax-backward " ")
(when (bolp)
- (loop do (forward-char -1)
+ (cl-loop do (forward-char -1)
while (looking-at "^ *$"))
(skip-syntax-backward " ")
- (case (char-before)
+ (cl-case (char-before)
((?} ?\;) t)
((?{) (dart-in-block-p (c-guess-basic-syntax))))))))
- [nongnu] elpa/dart-mode 1bba413 046/192: Bump version to 0.7., (continued)
- [nongnu] elpa/dart-mode 1bba413 046/192: Bump version to 0.7., ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode 592192c 054/192: Bump version to 0.9., ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode aba5eed 064/192: 'dart' must be found to find the analysis server snapshot, ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode 1b01681 065/192: Merge pull request #14 from hterkelsen/issue13, ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode 351db28 072/192: Lexically scope the library., ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode 1ccf8a0 073/192: Better handling and of analysis server messages., ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode a4d7a3c 075/192: Declare compatibility with flycheck 0.23., ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode 1b75622 079/192: Only mention marmalade in the README., ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode e338148 078/192: Get rid of busted flymake and formatter support., ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode 05fbd30 081/192: Merge pull request #24 from phst/master, ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode bd08208 082/192: Switch completely to cl-lib (#33),
ELPA Syncer <=
- [nongnu] elpa/dart-mode 1f65c88 083/192: Add LIMIT argument for looking-back (#34), ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode 1c9da5a 087/192: Explicitly load compile.el so that the compilation-error-regexp-* variables are defined (#41), ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode eea1000 093/192: Highlight hover dartdoc, ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode 907cba5 095/192: Indicate deprecated hovers, ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode 8e09b68 120/192: Exclusively use cl-lib to avoid byte-compilation inconsistencies, ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode 1249417 108/192: Better handle zero-argument functions, ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode 0277dad 107/192: Include parameter documentation, ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode 73d0ebc 135/192: Merge branch 'refactor-tests', ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode 4feac34 123/192: Make sure to provide the full buffer in dart-add-analysis-overlay, ELPA Syncer, 2021/08/29
- [nongnu] elpa/dart-mode e01234a 113/192: Use funcall rather than apply where appropriate, ELPA Syncer, 2021/08/29