[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/swift-mode 27b93dd 126/496: Merge pull request #34 from ap
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/swift-mode 27b93dd 126/496: Merge pull request #34 from ap4y/string_interpolation_improvements |
Date: |
Sun, 29 Aug 2021 11:33:21 -0400 (EDT) |
branch: elpa/swift-mode
commit 27b93dd6ebf83b3fec6ca39aa7aa92faf9051b28
Merge: 7826550 1a1d81c
Author: Bozhidar Batsov <bozhidar.batsov@gmail.com>
Commit: Bozhidar Batsov <bozhidar.batsov@gmail.com>
Merge pull request #34 from ap4y/string_interpolation_improvements
Improve font-lock regex for string interpolation
---
swift-mode.el | 2 +-
test/font-lock-tests.el | 2 ++
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/swift-mode.el b/swift-mode.el
index 84d00be..dd93a34 100644
--- a/swift-mode.el
+++ b/swift-mode.el
@@ -405,7 +405,7 @@
(remove-text-properties start end '(swift-interpolation-match-data))
(funcall
(syntax-propertize-rules
- ((rx (group "\\(" (*? any) ")"))
+ ((rx (group "\\(" (* (any alnum " " "(" ")" "+" "-" "*" "/")) ")"))
(0 (ignore (swift-syntax-propertize-interpolation)))))
start end)))
diff --git a/test/font-lock-tests.el b/test/font-lock-tests.el
index ed760d4..d4daffc 100644
--- a/test/font-lock-tests.el
+++ b/test/font-lock-tests.el
@@ -188,6 +188,8 @@ test will fail."
(check-face string-interpolation/has-variable-face/1
font-lock-variable-name-face "\"foo {{\\\(bar)}}\"")
(check-face string-interpolation/has-variable-face/2
font-lock-variable-name-face "\"{{\\\(bar)}}\"")
+(check-face string-interpolation/has-variable-face/3
font-lock-variable-name-face "\"\\\(bar\(1\){{\)}}\"")
+(check-face string-interpolation/has-variable-face/4
font-lock-variable-name-face "\"\\\(bar\(1\){{ + baz\(2\)\)}}\"")
(check-face string-interpolation/after-has-string-face/2 font-lock-string-face
"\"(foo \\\(bar){{baz}}\")")
(check-face self/has-keyword-face/1 font-lock-keyword-face "{{self}}.foo")
- [nongnu] elpa/swift-mode 1b3ebe8 046/496: Remove obsolete require, (continued)
- [nongnu] elpa/swift-mode 1b3ebe8 046/496: Remove obsolete require, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 90cdeb5 057/496: Configure travis, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 9714a0c 063/496: Fix docstring typo, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode e733088 073/496: Merge pull request #20 from ap4y/flycheck_plugin, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 5aa4010 082/496: Replace if not with unless, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 3a82dd5 085/496: Add mode menu, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 32e08b3 095/496: Add initial implementation of smie based indentation, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode b1334e1 101/496: Highlight interpolation expression via syntactic fontification, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode d053d31 109/496: Use greedy regex in interpolation highlighting to prevent issues with, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode ecb8a87 114/496: Use different lexer rule for case statement in enum to fix issues with, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 27b93dd 126/496: Merge pull request #34 from ap4y/string_interpolation_improvements,
ELPA Syncer <=
- [nongnu] elpa/swift-mode c08c3a1 138/496: Define dot-exp smie rule as combination of ids rather than expressions, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode b5bfbe0 154/496: Don't active flycheck checker by default, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode c73d653 151/496: Use correct function from cl-lib, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 67fd6a9 160/496: Fix indentation of multiline operator expressions, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 4b6d6f1 162/496: Add ckruse to the Acknowledgements in README, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 5675e1f 167/496: Merge pull request #65 from ckruse/fix_64, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 94d687d 173/496: Add required ELPA source, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 302e83d 194/496: Distinct generic type parameter from ">" operator when checking for, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 73cdda9 195/496: Don't put implicit semicolon after "(", ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 5c31636 200/496: Treat default token as case token, ELPA Syncer, 2021/08/29