Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable lexical binding - and some other stuff #139

Merged
merged 16 commits into from
Feb 21, 2024
Merged

Conversation

snogge
Copy link
Contributor

@snogge snogge commented Feb 19, 2024

Enable lexical-binding in all code and test files.
Some small changes were required.

While reading through all files I also tweaked most docstrings to pass checkdoc.
Also enabled CI testing for Emacs 29.1 and 29.2.
Added a test to check that mmm-version matches the Version tag.

The docstrings of mmm-ify and mmm-match region requires more thought.
Simplify by using pos-[be]ol instead of excursions.
The mmm class property :case-fold-search is passed as a keyword
argument to mmm-ify.  But that argument would shadow the dynamic
variable with the same name.  Use the name case-fold-search-arg with a
:case-fold-search keyword to avoid that problem.

The argument was used instead of a let-bound variable, so add a let
binding of case-fold-search around the function body.
boundp does not work with lexical variables.  Just use them and ignore
the errors.  ignore-error is not available until Emacs 27.1, use
explicit condition-case instead.
Instead of the obsolete point-at-bol.
mmm-utils.el Show resolved Hide resolved
mmm-class.el Show resolved Hide resolved
@dgutov
Copy link
Owner

dgutov commented Feb 20, 2024

Thank you, excellent job. Just two minor questions, see above.

@dgutov dgutov merged commit fec2640 into dgutov:master Feb 21, 2024
13 checks passed
@dgutov
Copy link
Owner

dgutov commented Feb 21, 2024

Thanks again!

@snogge snogge deleted the lexical branch February 21, 2024 22:07
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