diff options
| author | Harald Jörg <haj@posteo.de> | 2025-01-13 12:24:40 +0100 |
|---|---|---|
| committer | Harald Jörg <haj@posteo.de> | 2025-01-13 12:24:40 +0100 |
| commit | b74ac4af9408230645f1edb56c410b7a80bb41d2 (patch) | |
| tree | 1870231f83a14e87e65d69cc5d44d96e2c784bd8 /test | |
| parent | d66b8d4becb6804d3bd912a000dc64ccfdbe6810 (diff) | |
; cperl-mode.el: Allow bare $ in a signature (Bug#74245)
* lisp/progmodes/cperl-mode.el (cperl--signature-rx): Allow bare
sigils for unused parameters in signatures.
(cperl-find-pods-heres): Avoid $) at the end of a signature being
treated as the punctuation variable $) by treating this dollar as
punctuation
* test/lisp/progmodes/cperl-mode-tests.el
(cperl-test-signature-rx): Add ($first,$) as a valid signature,
remove ($) from the list of invalid signatures.
Diffstat (limited to 'test')
| -rw-r--r-- | test/lisp/progmodes/cperl-mode-tests.el | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/test/lisp/progmodes/cperl-mode-tests.el b/test/lisp/progmodes/cperl-mode-tests.el index 1f3c0ca3213..958ffe38a8b 100644 --- a/test/lisp/progmodes/cperl-mode-tests.el +++ b/test/lisp/progmodes/cperl-mode-tests.el @@ -622,10 +622,9 @@ Also includes valid cases with whitespace in strange places." "Test subroutine signatures." (skip-unless (eq cperl-test-mode #'cperl-mode)) (let ((valid - '("()" "( )" "($self, %params)" "(@params)")) + '("()" "( )" "($self, %params)" "(@params)" "($first,$)")) (invalid '("$self" ; missing paren - "($)" ; a subroutine signature "($!)" ; globals not permitted in a signature "(@par,%options)" ; two slurpy parameters "{$self}"))) ; wrong type of paren |
