[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master 88d1d46 115/433: (mmm-univ-get-mode): Signaled error on no
From: |
Dmitry Gutov |
Subject: |
[elpa] master 88d1d46 115/433: (mmm-univ-get-mode): Signaled error on non-fboundp modes. |
Date: |
Thu, 15 Mar 2018 19:43:47 -0400 (EDT) |
branch: master
commit 88d1d46fc86ffd8ea928979b5ca0780f253f4775
Author: mas <mas>
Commit: mas <mas>
(mmm-univ-get-mode): Signaled error on non-fboundp modes.
---
mmm-univ.el | 15 +++++++--------
1 file changed, 7 insertions(+), 8 deletions(-)
diff --git a/mmm-univ.el b/mmm-univ.el
index f5ddddf..3ddb91b 100644
--- a/mmm-univ.el
+++ b/mmm-univ.el
@@ -36,11 +36,13 @@
(defun mmm-univ-get-mode (string)
(string-match "[a-zA-Z-]+" string)
- (let ((modestr (match-string 0 string)))
- (and modestr
- (intern (if (equal (substring modestr -5) "-mode")
- modestr
- (concat modestr "-mode"))))))
+ (setq string (match-string 0 string))
+ (let ((modestr (intern (if (string-match "mode\\'" string)
+ string
+ (concat string "-mode")))))
+ (if (fboundp modestr)
+ modestr
+ (signal 'mmm-no-matching-submode nil))))
(mmm-add-classes
`((universal
@@ -48,9 +50,6 @@
:back "{%/~1%}"
:insert ((?/ universal "Submode: " @ "{%" str "%}" @ "\n" _ "\n"
@ "{%/" str "%}" @))
- :front-verify ,#'(lambda ()
- (fboundp
- (mmm-univ-get-mode (match-string 0))))
:match-submode mmm-univ-get-mode
:save-matches 1
)))
- [elpa] master c44e88a 102/433: # Updated., (continued)
- [elpa] master c44e88a 102/433: # Updated., Dmitry Gutov, 2018/03/15
- [elpa] master d640498 096/433: Released 0.4.3., Dmitry Gutov, 2018/03/15
- [elpa] master 63e6748 116/433: (mmm-here-doc-get-mode): Signaled non-fboundp here-document names., Dmitry Gutov, 2018/03/15
- [elpa] master bf3b29e 100/433: # Updated, Dmitry Gutov, 2018/03/15
- [elpa] master c76f5a3 099/433: Added to CVS., Dmitry Gutov, 2018/03/15
- [elpa] master 89daaab 103/433: # Added comment about universal mode., Dmitry Gutov, 2018/03/15
- [elpa] master a0e97ea 108/433: (mmm-save-local-variables): Changed `defcustom' to `defvar'., Dmitry Gutov, 2018/03/15
- [elpa] master 70a94da 109/433: (mmm-run-major-mode-hook): Added `ignore-errors' around each call., Dmitry Gutov, 2018/03/15
- [elpa] master 7a12efa 111/433: Added MASON_VERSION variable to keep track of that., Dmitry Gutov, 2018/03/15
- [elpa] master e7da5c1 117/433: # Updated., Dmitry Gutov, 2018/03/15
- [elpa] master 88d1d46 115/433: (mmm-univ-get-mode): Signaled error on non-fboundp modes.,
Dmitry Gutov <=
- [elpa] master 752288f 113/433: Added `mmm-no-matching-submode' error signal., Dmitry Gutov, 2018/03/15
- [elpa] master 3ee92f7 091/433: Moved commentary code to README.Mason., Dmitry Gutov, 2018/03/15
- [elpa] master efe3dbf 092/433: Wrote more about Mason., Dmitry Gutov, 2018/03/15
- [elpa] master e632aec 105/433: Limited matches to letter/dash strings that are fboundp., Dmitry Gutov, 2018/03/15
- [elpa] master b73a727 018/433: Added to CVS (formerly not under RCS)., Dmitry Gutov, 2018/03/15
- [elpa] master 28e978c 118/433: (mmm-ify-by-class): Added completion on all defined classes., Dmitry Gutov, 2018/03/15
- [elpa] master 34fbbd5 120/433: # Updated docstring., Dmitry Gutov, 2018/03/15
- [elpa] master d856bc2 106/433: Wrote about global classes, highlight, mode line, and hooks., Dmitry Gutov, 2018/03/15
- [elpa] master 3cd5dcb 123/433: Changed output name from `mmm' to `mmm-mode'., Dmitry Gutov, 2018/03/15
- [elpa] master a8a9d33 122/433: Updated file-variables class to handle prefixes., Dmitry Gutov, 2018/03/15