Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix new warnings enabled in upstream #117

Merged
merged 2 commits into from
Feb 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions color-identifiers-mode.el
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@

;;; Code:

(require 'advice)
(require 'nadvice)
(require 'color)
(require 'dash)
(require 'cl-lib)
Expand Down Expand Up @@ -65,7 +65,7 @@
`color-identifiers:modes-alist' that is relevant to the current
major mode")

(defadvice enable-theme (after color-identifiers:regen-on-theme-change)
(defun color-identifiers:regen-on-theme-change(_)
"Regenerate colors for color-identifiers-mode on theme change."
(color-identifiers:regenerate-colors))

Expand Down Expand Up @@ -661,11 +661,11 @@ mode. This variable memoizes the result of the declaration scan function.")
(add-to-list 'font-lock-extra-managed-props 'color-identifiers:fontified)
(font-lock-add-keywords nil '((color-identifiers:colorize . default)) t)
(color-identifiers:enable-timer)
(ad-activate 'enable-theme)))
(advice-add 'enable-theme :after #'color-identifiers:regen-on-theme-change)))
(when color-identifiers:timer
(cancel-timer color-identifiers:timer))
(font-lock-remove-keywords nil '((color-identifiers:colorize . default)))
(ad-deactivate 'enable-theme))
(advice-remove 'enable-theme #'color-identifiers:regen-on-theme-change))
(color-identifiers:refontify))

;;;###autoload
Expand Down
1 change: 1 addition & 0 deletions tests.el
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
;;; -*- lexical-binding: t -*-
(require 'ert)
(require 'color-identifiers-mode)

Expand Down
Loading