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

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

[elpa] externals/phps-mode d2e5a03 228/405: Updated indentation algorith


From: Stefan Monnier
Subject: [elpa] externals/phps-mode d2e5a03 228/405: Updated indentation algorithm document and README
Date: Sat, 13 Jul 2019 10:00:18 -0400 (EDT)

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

    Updated indentation algorithm document and README
---
 README.md                     | 14 ++++++++++----
 docs/indentation-algorithm.md |  6 ++++++
 2 files changed, 16 insertions(+), 4 deletions(-)

diff --git a/README.md b/README.md
index e9aed59..3e75bb8 100644
--- a/README.md
+++ b/README.md
@@ -7,17 +7,19 @@ An Emacs major mode for PHP scripting language which aims at 
making a full seman
 *With current progress estimates:*
 
 * Flycheck support (100%)
-* Lexer based on official PHP re2c lexer (100%)
 * Syntax coloring based on lexer tokens (100%)
-* PSR based indentation based on lexer tokens (90%)
+* PSR based indentation based on lexer tokens (100%)
+* Lexer based on official PHP re2c lexer (90%)
 * Incremental lexer and syntax coloring after buffer changes (75%)
-* Wisent LALR parser based on official PHP yacc parser automatically converted 
(60%)
+* Wisent LALR parser based on official PHP yacc parser automatically converted 
(50%)
 * Full integration with Emacs Semantic subsystem (30%)
+* Imenu support (0%)
 * Flymake support (0%)
 * PSR-2 auto-formatting tool based on lexer tokens (0%)
 * Travis support (0%)
 * Add to MELPA (0%)
 * Add to ELPA (0%)
+* Use master branch for stable releases and develop for unstable (0%)
 
 ## Unit tests
 
@@ -27,6 +29,8 @@ If you have emacs at a customized location prefix the 
commands with your path, i
 
 ### Lexer
 
+Token generation
+
 ``` bash
 make test-lexer
 ```
@@ -41,13 +45,15 @@ make test-parser
 
 ### Functions
 
+Indentations, imenu, semantic subsystem
+
 ``` bash
 make test-functions
 ```
 
 ### Integration tests
 
-Not working yet
+Not ready yet
 
 ``` bash
 make test-integration
diff --git a/docs/indentation-algorithm.md b/docs/indentation-algorithm.md
index 4913064..c6fd0be 100644
--- a/docs/indentation-algorithm.md
+++ b/docs/indentation-algorithm.md
@@ -45,6 +45,12 @@ foreach token in buffer:
     
     if we reached end of a line:
         
+        if this-token or last token is a dot:
+            concatentation-level = 1;
+        else:
+            concatentation-level = 0;
+        endif;
+        
         indent-start = indent;
         
         if new-token-line-start is more than one line after 
last-token-line-start AND token is not T_CLOSE_TAG:



reply via email to

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