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

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

[nongnu] elpa/php-mode 5e04c9269f 05/11: Merge pull request #750 from em


From: ELPA Syncer
Subject: [nongnu] elpa/php-mode 5e04c9269f 05/11: Merge pull request #750 from emacs-php/support/emacs29
Date: Sun, 23 Jul 2023 16:01:08 -0400 (EDT)

branch: elpa/php-mode
commit 5e04c9269f3e1378733c50e44a47d8cb4acfa59c
Merge: 73d2dedb81 7774c8d743
Author: USAMI Kenta <tadsan@pixiv.com>
Commit: GitHub <noreply@github.com>

    Merge pull request #750 from emacs-php/support/emacs29
    
    Support Emacs 29.1
---
 .github/workflows/test.yml    |   1 +
 CHANGELOG.md                  |   8 +-
 README.ja.md                  |   2 +-
 README.md                     |   2 +-
 tests/php-mode-test.el        |   3 +-
 tests/type-hints.php.29.faces | 590 ++++++++++++++++++++++++++++++++++++++++++
 6 files changed, 602 insertions(+), 4 deletions(-)

diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index b333e2cbf9..72f1fd8966 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -19,6 +19,7 @@ jobs:
           - "27.2"
           - "28.1"
           - "28.2"
+          - release-snapshot
           - snapshot
         include:
           - emacs_version: snapshot
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 3652ffd09b..02e51eaa24 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -2,7 +2,13 @@
 
 All notable changes of the PHP Mode 1.19.1 release series are documented in 
this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles.
 
-<!-- ## Unreleased -->
+## Unreleased
+
+### Added
+
+ * **Support Emacs 29.1** ([#750])
+
+[#750]: https://github.com/emacs-php/php-mode/pull/750
 
 ## [1.24.3] - 2023-03-19
 
diff --git a/README.ja.md b/README.ja.md
index 65e31d7f6b..b56a66a7c4 100644
--- a/README.ja.md
+++ b/README.ja.md
@@ -1,7 +1,7 @@
 <div align="center">
   <h1>Emacs PHP Mode</h1>
 
-[![Emacs: 
28.2](https://img.shields.io/badge/Emacs-28.2-blue.svg)](https://www.gnu.org/software/emacs/)
+[![Emacs: 
29.1](https://img.shields.io/badge/Emacs-29.1-blue.svg)](https://www.gnu.org/software/emacs/)
 [![lang: PHP 
8.2](https://img.shields.io/badge/lang-PHP%208.2-brightgreen.svg)](https://php.net/manual/migration82.php)
 [![lang: PHP 
7](https://img.shields.io/badge/lang-PHP%207-green.svg)](https://php.net/downloads.php)
 [![Build 
Status](https://github.com/emacs-php/php-mode/workflows/CI/badge.svg)](https://github.com/emacs-php/php-mode/actions)
diff --git a/README.md b/README.md
index 9527810cb5..829199d406 100644
--- a/README.md
+++ b/README.md
@@ -1,7 +1,7 @@
 <div align="center">
   <h1>Emacs PHP Mode</h1>
 
-[![Emacs: 
28.2](https://img.shields.io/badge/Emacs-28.2-blue.svg)](https://www.gnu.org/software/emacs/)
+[![Emacs: 
29.1](https://img.shields.io/badge/Emacs-29.1-blue.svg)](https://www.gnu.org/software/emacs/)
 [![lang: PHP 
8.2](https://img.shields.io/badge/lang-PHP%208.2-brightgreen.svg)](https://php.net/manual/migration82.php)
 [![lang: PHP 
7](https://img.shields.io/badge/lang-PHP%207-green.svg)](https://php.net/downloads.php)
 [![Build 
Status](https://github.com/emacs-php/php-mode/workflows/CI/badge.svg)](https://github.com/emacs-php/php-mode/actions)
diff --git a/tests/php-mode-test.el b/tests/php-mode-test.el
index 0dae822e95..b827fcfcde 100644
--- a/tests/php-mode-test.el
+++ b/tests/php-mode-test.el
@@ -596,7 +596,8 @@ style from Drupal."
 
 (ert-deftest php-mode-test-type-hints ()
   "Test highlighting of type hints and return types."
-  (with-php-mode-test ("type-hints.php" :faces t)))
+  (with-php-mode-test ("type-hints.php" :faces (cond ((version<= "29" 
emacs-version) ".29.faces")
+                                                     (t)))))
 
 (ert-deftest php-mode-test-static-method-calls ()
   "Test highlighting of static method calls which are named the same
diff --git a/tests/type-hints.php.29.faces b/tests/type-hints.php.29.faces
new file mode 100644
index 0000000000..14cf581e53
--- /dev/null
+++ b/tests/type-hints.php.29.faces
@@ -0,0 +1,590 @@
+;; -*- mode: emacs-lisp -*-
+(("<?php" . php-php-tag)
+ ("
+
+")
+ ("class" . php-class-declaration)
+ (" ")
+ ("SomeClass" . font-lock-type-face)
+ ("
+{
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("none" . php-function-name)
+ ("(")
+ ("$" . php-variable-sigil)
+ ("title" . php-variable-name)
+ ("): ")
+ ("void" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("title" . php-function-name)
+ ("(")
+ ("string" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("title" . php-variable-name)
+ ("): ")
+ ("string" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("nullableTitle" . php-function-name)
+ ("(")
+ ("?string" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("title" . php-variable-name)
+ ("): ")
+ ("?string" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("number" . php-function-name)
+ ("(")
+ ("int" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("number" . php-variable-name)
+ ("): ")
+ ("int" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("nullableNumber" . php-function-name)
+ ("(")
+ ("?int" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("number" . php-variable-name)
+ ("): ")
+ ("?int" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("otherNumber" . php-function-name)
+ ("(")
+ ("float" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("number" . php-variable-name)
+ ("): ")
+ ("float" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("nullableOtherNumber" . php-function-name)
+ ("(")
+ ("?float" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("number" . php-variable-name)
+ ("): ")
+ ("?float" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("flag" . php-function-name)
+ ("(")
+ ("bool" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("flag" . php-variable-name)
+ ("): ")
+ ("bool" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("nullableFlag" . php-function-name)
+ ("(")
+ ("?bool" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("flag" . php-variable-name)
+ ("): ")
+ ("?bool" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("options" . php-function-name)
+ ("(")
+ ("array" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("options" . php-variable-name)
+ ("): ")
+ ("array" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("nullableOptions" . php-function-name)
+ ("(")
+ ("?array" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("options" . php-variable-name)
+ ("): ")
+ ("?array" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("object" . php-function-name)
+ ("(stdClass ")
+ ("$" . php-variable-sigil)
+ ("object" . php-variable-name)
+ ("): ")
+ ("stdClass" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("nullableObject" . php-function-name)
+ ("(")
+ ("?stdClass" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("object" . php-variable-name)
+ ("): ")
+ ("?stdClass" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("nsObject" . php-function-name)
+ ("(")
+ ("\\path\\to\\my\\Object" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("object" . php-variable-name)
+ ("): ")
+ ("\\path\\to\\my\\Object" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("nullableNsObject" . php-function-name)
+ ("(")
+ ("?\\path\\to\\my\\Object" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("object" . php-variable-name)
+ ("): ")
+ ("?\\path\\to\\my\\Object" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("callable" . php-function-name)
+ ("(")
+ ("callable" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("callable" . php-variable-name)
+ ("): ")
+ ("callable" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("nullableCallable" . php-function-name)
+ ("(")
+ ("?callable" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("callable" . php-variable-name)
+ ("): ")
+ ("?callable" . font-lock-type-face)
+ ("
+    {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("someFunction" . php-function-name)
+ ("(
+        ")
+ ("$" . php-variable-sigil)
+ ("any" . php-variable-name)
+ (",
+        ")
+ ("string" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("name" . php-variable-name)
+ (",
+        ")
+ ("int" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("value" . php-variable-name)
+ (",
+        ")
+ ("bool" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("flag" . php-variable-name)
+ (",
+        ")
+ ("array" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("options" . php-variable-name)
+ (",
+        ")
+ ("stdClass" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("object" . php-variable-name)
+ (",
+        ")
+ ("\\path\\to\\my\\Object" . font-lock-type-face)
+ (" ")
+ ("$" . php-variable-sigil)
+ ("nsObject" . php-variable-name)
+ ("
+    ): ")
+ ("void" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getNone" . php-function-name)
+ ("(
+    ): ")
+ ("void" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getTitle" . php-function-name)
+ ("(
+    ): ")
+ ("string" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getNullableTitle" . php-function-name)
+ ("(
+    ): ")
+ ("?string" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getNumber" . php-function-name)
+ ("(
+    ): ")
+ ("int" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getNullableNumber" . php-function-name)
+ ("(
+    ): ")
+ ("?int" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getOtherNumber" . php-function-name)
+ ("(
+    ): ")
+ ("float" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getNullableOtherNumber" . php-function-name)
+ ("(
+    ): ")
+ ("?float" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getFlag" . php-function-name)
+ ("(
+    ): ")
+ ("bool" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getNullableFlag" . php-function-name)
+ ("(
+    ): ")
+ ("?bool" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getOptions" . php-function-name)
+ ("(
+    ): ")
+ ("array" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getNullableOptions" . php-function-name)
+ ("(
+    ): ")
+ ("?array" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getObject" . php-function-name)
+ ("(
+    ): ")
+ ("stdClass" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getNullableObject" . php-function-name)
+ ("(
+    ): ")
+ ("?stdClass" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("abstract" . php-keyword)
+ (" ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getOtherObject" . php-function-name)
+ ("(
+    ): ")
+ ("stdClass" . font-lock-type-face)
+ (";
+
+    ")
+ ("abstract" . php-keyword)
+ (" ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getOtherNullableObject" . php-function-name)
+ ("(
+    ): ")
+ ("?stdClass" . font-lock-type-face)
+ (";
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getNsObject" . php-function-name)
+ ("(
+    ): ")
+ ("\\path\\to\\my\\Object" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getNullableNsObject" . php-function-name)
+ ("(
+    ): ")
+ ("?\\path\\to\\my\\Object" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getCallable" . php-function-name)
+ ("(
+    ): ")
+ ("callable" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("getNullableCallable" . php-function-name)
+ ("(
+    ): ")
+ ("?callable" . font-lock-type-face)
+ (" {
+    }
+
+    ")
+ ("public" . php-keyword)
+ (" ")
+ ("function" . php-keyword)
+ (" ")
+ ("neverReturn" . php-function-name)
+ ("(
+    ): ")
+ ("never" . font-lock-type-face)
+ (" {
+    }
+}
+"))



reply via email to

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