branch: externals/phps-mode
commit 95078e0db2d27edd6c7744813ff92cf82497ca4c
Author: Christian Johansson <christ...@cvj.se>
Commit: Christian Johansson <christ...@cvj.se>

    Added SDT for increment variable production
---
 phps-mode-ast.el | 23 +++++++++++++++++++++++
 1 file changed, 23 insertions(+)

diff --git a/phps-mode-ast.el b/phps-mode-ast.el
index b041e977da..3a5e19eea0 100644
--- a/phps-mode-ast.el
+++ b/phps-mode-ast.el
@@ -489,6 +489,19 @@
      ast-object))
  phps-mode-parser--table-translations)
 
+;; expr -> (variable T_INC)
+(puthash
+ 353
+ (lambda(args _terminals)
+   (let ((ast-object
+          (list
+           'ast-type
+           'increment-variable
+           'variable
+           (nth 0 args))))
+     ast-object))
+ phps-mode-parser--table-translations)
+
 ;; expr -> (variable "=" expr)
 (puthash
  337
@@ -1129,6 +1142,16 @@
                     argument)
                    bookkeeping-stack))))
 
+             ((equal type 'increment-variable)
+              (push
+               (list
+                (list
+                 class
+                 function
+                 namespace)
+                (plist-get item 'variable))
+               bookkeeping-stack))
+
              )))))
     (setq
      phps-mode-ast--bookkeeping

Reply via email to