Lines 1-61
Link Here
|
1 |
From 75d3ee1ead7557175e6aeb2ad8efdd73ee3c9332 Mon Sep 17 00:00:00 2001 |
|
|
2 |
From: Charlie McMackin <charliemac@gmail.com> |
3 |
Date: Sun, 29 Sep 2019 11:52:54 -0500 |
4 |
Subject: [PATCH] Replace rx-form with rx-to-string |
5 |
|
6 |
`rx-form` is being removed in an upcoming version of Emacs and its rewrite of |
7 |
`rx`. Replacing it with `rx-to-string` is backwards and future compatible. |
8 |
--- |
9 |
php.el | 36 ++++++++++++++++++------------------ |
10 |
1 file changed, 18 insertions(+), 18 deletions(-) |
11 |
|
12 |
diff --git php.el php.el |
13 |
index 64286da..ea36fc3 100644 |
14 |
--- php.el |
15 |
+++ php.el |
16 |
@@ -177,24 +177,24 @@ keywords that can appear in method signatures, e.g. 'final' and |
17 |
which will be the name of the method." |
18 |
(when (stringp visibility) |
19 |
(setq visibility (list visibility))) |
20 |
- (rx-form `(: line-start |
21 |
- (* (syntax whitespace)) |
22 |
- ,@(if visibility |
23 |
- `((* (or "abstract" "final" "static") |
24 |
- (+ (syntax whitespace))) |
25 |
- (or ,@visibility) |
26 |
- (+ (syntax whitespace)) |
27 |
- (* (or "abstract" "final" "static") |
28 |
- (+ (syntax whitespace)))) |
29 |
- '((* (* (or "abstract" "final" "static" |
30 |
- "private" "protected" "public") |
31 |
- (+ (syntax whitespace)))))) |
32 |
- "function" |
33 |
- (+ (syntax whitespace)) |
34 |
- (? "&" (* (syntax whitespace))) |
35 |
- (group (+ (or (syntax word) (syntax symbol)))) |
36 |
- (* (syntax whitespace)) |
37 |
- "("))) |
38 |
+ (rx-to-string `(: line-start |
39 |
+ (* (syntax whitespace)) |
40 |
+ ,@(if visibility |
41 |
+ `((* (or "abstract" "final" "static") |
42 |
+ (+ (syntax whitespace))) |
43 |
+ (or ,@visibility) |
44 |
+ (+ (syntax whitespace)) |
45 |
+ (* (or "abstract" "final" "static") |
46 |
+ (+ (syntax whitespace)))) |
47 |
+ '((* (* (or "abstract" "final" "static" |
48 |
+ "private" "protected" "public") |
49 |
+ (+ (syntax whitespace)))))) |
50 |
+ "function" |
51 |
+ (+ (syntax whitespace)) |
52 |
+ (? "&" (* (syntax whitespace))) |
53 |
+ (group (+ (or (syntax word) (syntax symbol)))) |
54 |
+ (* (syntax whitespace)) |
55 |
+ "("))) |
56 |
|
57 |
(defun php-create-regexp-for-classlike (type) |
58 |
"Accepts a `TYPE' of a 'classlike' object as a string, such as |
59 |
-- |
60 |
2.23.0 |
61 |
|