Skip to content

Commit 3dcf800

Browse files
committed
Fix indentation for #[Attributes]
1 parent df1e864 commit 3dcf800

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lisp/php-mode.el

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -909,9 +909,9 @@ This is was done due to the problem reported here:
909909
(unless (php-in-string-or-comment-p)
910910
(or
911911
;; Detect PHP8 attribute: <<Attribute()>>
912-
(when (and (< 2 pos) (< 2 (- pos (c-point 'bol))))
913-
(backward-char 2)
914-
(looking-at-p ">>\\s-*\\(?:<<\\|$\\)"))
912+
(when (and (< 1 pos) (< 1 (- pos (c-point 'bol))))
913+
(backward-char 1)
914+
(looking-at-p (eval-when-compile (rx "]" (* (syntax whitespace)) (or "#[" line-end)))))
915915
;; Detect HTML/XML tag and PHP tag (<?php, <?=, ?>)
916916
(when php-mode-template-compatibility
917917
(beginning-of-line)

0 commit comments

Comments
 (0)