emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/phps-mode dd8d800 004/405: Using coloring overlay for c


From: Stefan Monnier
Subject: [elpa] externals/phps-mode dd8d800 004/405: Using coloring overlay for comments as well
Date: Sat, 13 Jul 2019 09:59:28 -0400 (EDT)

branch: externals/phps-mode
commit dd8d800dd3a2e8588e70638dad733c0fe4737cb5
Author: Christian Johansson <address@hidden>
Commit: Christian Johansson <address@hidden>

    Using coloring overlay for comments as well
---
 phps-lexer.el       | 3 +--
 tests/php/class.php | 2 +-
 2 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/phps-lexer.el b/phps-lexer.el
index 4ba9eef..a708d6e 100644
--- a/phps-lexer.el
+++ b/phps-lexer.el
@@ -189,7 +189,6 @@
   "Move forward to POSITION."
   (setq semantic-lex-end-point position))
 
-;; TODO Use font-lock-syntactic-face-function instead?
 (defun phps-mode/COLOR_SYNTAX (token start end)
   "Syntax coloring for TOKEN from START to END."
   ;; Syntax coloring
@@ -213,7 +212,7 @@
     (overlay-put (make-overlay start end) 'font-lock-face 
'font-lock-variable-name-face))
 
    ((string= token 'T_COMMENT)
-    (add-text-properties start end '(font-lock-face font-lock-comment-face)))
+    (overlay-put (make-overlay start end) 'font-lock-face 
'font-lock-comment-face))
 
    ((string= token 'T_DOC_COMMENT)
     (overlay-put (make-overlay start end) 'font-lock-face 
'font-lock-comment-delimiter-face))
diff --git a/tests/php/class.php b/tests/php/class.php
index e43c12b..05a5e11 100644
--- a/tests/php/class.php
+++ b/tests/php/class.php
@@ -1,7 +1,7 @@
 <?php
 /**
  * Some comments here
- *  @todo was here
+ * @todo was here
  */
 
 class MyClass {



reply via email to

[Prev in Thread] Current Thread [Next in Thread]