diff --git a/lisp/php-mode.el b/lisp/php-mode.el index 9c582648..917a28c7 100644 --- a/lisp/php-mode.el +++ b/lisp/php-mode.el @@ -481,7 +481,7 @@ In that case set to `NIL'." (c-lang-defconst c-primitive-type-kwds php '("int" "integer" "bool" "boolean" "float" "double" "real" - "string" "object" "void" "mixed")) + "string" "object" "void" "mixed" "never")) (c-lang-defconst c-class-decl-kwds "Keywords introducing declarations where the following block (if any) diff --git a/tests/type-hints.php b/tests/type-hints.php index bfe987fc..571b7e0f 100644 --- a/tests/type-hints.php +++ b/tests/type-hints.php @@ -154,4 +154,8 @@ public function getCallable( public function getNullableCallable( ): ?callable { } + + public function neverReturn( + ): never { + } } diff --git a/tests/type-hints.php.faces b/tests/type-hints.php.faces index 4e289d06..86d88aa0 100644 --- a/tests/type-hints.php.faces +++ b/tests/type-hints.php.faces @@ -1,10 +1,14 @@ ;; -*- mode: emacs-lisp -*- (("