File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -1013,13 +1013,16 @@ this ^ lineup"
1013
1013
(defun php-syntax-propertize-hash-line-comment (_start end )
1014
1014
" Apply propertize # comment (without PHP8 Attributes) from START to END."
1015
1015
(unless php-mode-use-php7-syntax-table
1016
- (while (< (point ) (min end (point-max )))
1017
- (let ((line-end (line-end-position )))
1016
+ (let (line-end last-pos)
1017
+ (while (and (< (point ) (min end (point-max )))
1018
+ (not (eq (point ) last-pos)))
1019
+ (setq line-end (line-end-position ))
1018
1020
(when (and (search-forward " #" line-end t )
1019
1021
(not (php-in-string-or-comment-p))
1020
1022
(not (looking-at " [[]" )))
1021
1023
(c-put-char-property (1- (point )) 'syntax-table (string-to-syntax " <" ))
1022
1024
(c-put-char-property line-end 'syntax-table (string-to-syntax " >" )))
1025
+ (setq last-pos (point ))
1023
1026
(move-beginning-of-line 2 )))))
1024
1027
1025
1028
(defun php-heredoc-syntax ()
You can’t perform that action at this time.
0 commit comments