[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/phps-mode b2ff76e 283/405: Started on debugging switch
From: |
Stefan Monnier |
Subject: |
[elpa] externals/phps-mode b2ff76e 283/405: Started on debugging switch indentation bug |
Date: |
Sat, 13 Jul 2019 10:00:32 -0400 (EDT) |
branch: externals/phps-mode
commit b2ff76e0fae75c007caca8f62db420a98de71fc1
Author: Christian Johansson <address@hidden>
Commit: Christian Johansson <address@hidden>
Started on debugging switch indentation bug
---
phps-mode-functions.el | 4 ++--
phps-mode-test-functions.el | 3 +--
2 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/phps-mode-functions.el b/phps-mode-functions.el
index 69d302e..72be62d 100644
--- a/phps-mode-functions.el
+++ b/phps-mode-functions.el
@@ -501,7 +501,7 @@
(if allow-custom-column-decrement
(progn
(setq column-level (- column-level (-
nesting-start nesting-end)))
- (setq allow-custom-column-increment nil))
+ (setq allow-custom-column-decrement nil))
(setq column-level (1- column-level)))
;; Prevent negative column-values
@@ -515,7 +515,7 @@
(if allow-custom-column-decrement
(progn
(setq temp-post-indent (- temp-post-indent (-
nesting-start nesting-end)))
- (setq allow-custom-column-increment nil))
+ (setq allow-custom-column-decrement nil))
(setq temp-post-indent (1- temp-post-indent)))
;; Prevent negative column-values
diff --git a/phps-mode-test-functions.el b/phps-mode-test-functions.el
index 2394a13..815ff60 100644
--- a/phps-mode-test-functions.el
+++ b/phps-mode-test-functions.el
@@ -343,7 +343,6 @@
(message "Indent: %s" (phps-mode-test-hash-to-list
(phps-mode-functions-get-lines-indent)))
(should (equal '((1 (0 0)) (2 (0 0)) (3 (1 0)) (4 (2 0)) (5 (3 0)) (6 (3
0)) (7 (2 0)) (8 (3 0)) (9 (2 0)) (10 (3 0)) (11 (1 0)) (12 (1 0)) (13 (2 0))
(14 (2 0)) (15 (1 0)) (16 (0 0))) (phps-mode-test-hash-to-list
(phps-mode-functions-get-lines-indent)))))
-
(phps-mode-test-with-buffer
"<?php\nif (true) {\n switch ($condition) {\n case true:\n
echo 'here';\n echo 'here 2';\n case false:\n
echo 'here 4';\n default:\n echo 'here 3';\n }\n
sprintf(__(\n 'Error: %s',\n $error\n ));\n}\n"
"Curly switch, case, default with exception after it"
@@ -633,7 +632,7 @@
(defun phps-mode-test-functions ()
"Run test for functions."
;; (setq debug-on-error t)
- ;; (setq phps-mode-functions-verbose t)
+ (setq phps-mode-functions-verbose t)
(phps-mode-test-functions-get-lines-lindent-if)
(phps-mode-test-functions-get-lines-indent-classes)
(phps-mode-test-functions-get-lines-indent-inline-if)
- [elpa] externals/phps-mode 46147f4 287/405: Fixed bug with undefined token-end-line-number in new buffers, (continued)
- [elpa] externals/phps-mode 46147f4 287/405: Fixed bug with undefined token-end-line-number in new buffers, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode 66edaca 286/405: Improved lexing of comment version doc comment, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode 55f61b0 296/405: New algorithm for concatenation indentation passes tests, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode 9069d0a 300/405: Concatenation indentation now uses stack, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode e639ea3 299/405: Indent passing new concatenation tests, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode 5be3560 291/405: Adding more indent examples from PSR-2, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode 74ab2a7 294/405: Work on incremental lexer and failing test for indent, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode b31f817 292/405: Added all examples from PSR-2 as tests for indentation, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode 2087abd 282/405: Added two failing tests for switch indentation, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode 43c13b4 295/405: Started on new algorithm for concatenation indentation, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode b2ff76e 283/405: Started on debugging switch indentation bug,
Stefan Monnier <=
- [elpa] externals/phps-mode 1aadb1b 285/405: Added failing lexer test for comment vs doc-comment, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode 95de04b 274/405: New layout for lexer grammar passes unit tests, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode 00d3568 290/405: Added indentation examples from official PSR-2, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode ec3fd41 289/405: Added failing indent test for mixed concatenation and function call, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode cc77604 284/405: Fixed bug with indentation after switch case statements, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode eeffdb2 315/405: Fixed trailing white-space, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode 02b69f5 304/405: Tests for PSR-2 now passes with new algorithms, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode b251a1e 314/405: Got unit tests for wrapping region in symbols working, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode 20199b0 307/405: Added byte-compiled Lisp to gitignore, Stefan Monnier, 2019/07/13
- [elpa] externals/phps-mode a0b7695 316/405: Passes unit tests for integration with electric-pair, Stefan Monnier, 2019/07/13