From: Mark Wooding Date: Sun, 25 Nov 2018 13:52:25 +0000 (+0000) Subject: el/dot-emacs.el (mdw-fontify-pythonic): Numbers can't contain `_'. X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~mdw/git/profile/commitdiff_plain/b834ced3b4b80a75fd31eb90764fffa8499dc814 el/dot-emacs.el (mdw-fontify-pythonic): Numbers can't contain `_'. Where did I get the idea that they could from? This isn't even Python 3. --- diff --git a/el/dot-emacs.el b/el/dot-emacs.el index f0569e6..9453332 100644 --- a/el/dot-emacs.el +++ b/el/dot-emacs.el @@ -2865,9 +2865,9 @@ (defun mdw-fontify-pythonic (keywords) '(0 font-lock-keyword-face)) ;; At least numbers are simpler than C. - (list (concat "\\_<0\\([xX][0-9a-fA-F_]+\\|[0-7_]+\\)\\|" - "\\_<[0-9][0-9_]*\\(\\.[0-9_]*\\|\\)" - "\\([eE]\\([-+]\\|\\)[0-9_]+\\|[lL]\\|\\)") + (list (concat "\\_<0\\([xX][0-9a-fA-F]+\\|[0-7]+\\)\\|" + "\\_<[0-9][0-9]*\\(\\.[0-9]*\\|\\)" + "\\([eE]\\([-+]\\|\\)[0-9]+\\|[lL]\\|\\)") '(0 mdw-number-face)) ;; And anything else is punctuation.