Skip to content

Make lisp lint happier. - #29

Open
matthewpersico wants to merge 1 commit into
HaraldJoerg:upstreamfrom
matthewpersico:elisp-lint
Open

Make lisp lint happier.#29
matthewpersico wants to merge 1 commit into
HaraldJoerg:upstreamfrom
matthewpersico:elisp-lint

Conversation

@matthewpersico

Copy link
Copy Markdown

These are the errors I got, which I fixed with this PR against the upstream brach:

File            Line Col Level    ID Message(checker)
 cperl-mode.el  1494   5 warning     Closing parens should not be wrapped onto new lines. (emacs-lisp-package)
 cperl-mode.el  2265   7 warning     Closing parens should not be wrapped onto new lines. (emacs-lisp-package)
 cperl-mode.el  4061   7 warning     Closing parens should not be wrapped onto new lines. (emacs-lisp-package)
 cperl-mode.el  4121   4 warning     Closing parens should not be wrapped onto new lines. (emacs-lisp-package)
 cperl-mode.el  4252  17 warning     Closing parens should not be wrapped onto new lines. (emacs-lisp-package)
 cperl-mode.el  6564  21 warning     Closing parens should not be wrapped onto new lines. (emacs-lisp-package)
 cperl-mode.el  6565  20 warning     Closing parens should not be wrapped onto new lines. (emacs-lisp-package)
 cperl-mode.el  6582  32 warning     Closing parens should not be wrapped onto new lines. (emacs-lisp-package)
 cperl-mode.el  6583  31 warning     Closing parens should not be wrapped onto new lines. (emacs-lisp-package)
 cperl-mode.el  6584  21 warning     Closing parens should not be wrapped onto new lines. (emacs-lisp-package)

These issues still remain. Not sure how much change to inflict to correct them:

File            Line Col Level    ID Message(checker)
 cperl-mode.el     1   1 warning     "Version:" or "Package-Version:" header is missing. MELPA will handle this, but other archives will not. (emacs-lisp-package)
 cperl-mode.el     1   1 warning     Including "Emacs" in the package summary is usually redundant. (emacs-lisp-package)
 cperl-mode.el     1   1 error       Package should have a Homepage or URL header. (emacs-lisp-package)
 cperl-mode.el  6289   4 warning     `eval-after-load' is for use in configurations, and should rarely be used in packages. (emacs-lisp-package)
 cperl-mode.el  6759   4 warning     `eval-after-load' is for use in configurations, and should rarely be used in packages. (emacs-lisp-package)

@HaraldJoerg

Copy link
Copy Markdown
Owner

Guilty, your honor, with regard to the closing parens. While developing, I keep them on separate lines because it is easier to insert/remove code that way, and often enough I forget to fix it before committing.

As for applying the PR: You are probably aware that CPerl mode is part of Emacs, and this is just a mirror. I can commit it over there, with some amendments. First, The Emacs repository has a rule: all contributions need the copyright to be transferred to the FSF. If you have not done that paperwork, we can skip it under the rule "trivial fixes with less than 15 lines" - so actually no problem.
Second, the Emacs repository has rules for commit messages in their CONTRIBUTE guide: they generate a changelog from the commit messages automatically, your patch doesn't really fit. If you want your name in the commit history, you can amend your commit message, and I can git am your patch as is. You can also write an official Emacs bug report to the mailing list bug-gnu-emacs@gnu.org and attach the patch. Or, I write the commit message, giving you credits there, and commit under my own name. Whatever you prefer...

The remaining issues can and will eventually be fixed, but not immediately.

  • Cperl mode used to have its own version number long ago. It was eliminated after the original CPerl upstream source by Ilya Zakharevich had dried up. It might come again once CPerl mode is dual-life in the Emacs repository and GNU ELPA, a process which I can't do on my own.
  • I'll remove "Emacs" from the package summary, probably when I commit the updates for Perl 5.44.
  • There is no URL: CPerl mode is not a package (yet).
  • The uses of eval-after-use in cperl-mode.el actually is one of the rare cases where it is needed. It can be eliminated once the minimum Emacs version for which this CPerl mode can be used is bumped to 28 ... and some rewrites which take time, so not with the Perl 5.44 update.

@matthewpersico
matthewpersico marked this pull request as draft July 23, 2026 11:26
@HaraldJoerg
HaraldJoerg marked this pull request as ready for review July 23, 2026 11:32
@matthewpersico

Copy link
Copy Markdown
Author

Thank you. I tried to figure out where to submit the changes in the emacs repo, but figured let me record them, and the issues, here so that at least they are recorded somewhere.

I’ll take the “remaining issues” and add them as individual issues here, so that they can be more properly tracked, unless there’s a place to put them on the emacs site. I did not expect them to be addressed now, just wanted to put them someplace for when (if?) you do melpa-ize it.

Thank you for picking this up and keeping it up to date with Perl updates! You should put a Patreon or a Buy-Me-a-Coffee link someplace. I’d be happy to throw you a few dollars, pounds, euros, whatever.

@matthewpersico

Copy link
Copy Markdown
Author

I am not home at the moment. Let me review your comments and I’ll Do The Right Thing upstream. Let’s leave this PR open for the moment until I can accomplish that.

@matthewpersico

Copy link
Copy Markdown
Author

When you commit the updates for 5.44, feel free to fix the trailing parens. I don't need to be the committer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants