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

Automated Resyntax fixes #1429

Open
wants to merge 19 commits into
base: master
Choose a base branch
from
Open

Automated Resyntax fixes #1429

wants to merge 19 commits into from

Conversation

resyntax-ci[bot]
Copy link
Contributor

@resyntax-ci resyntax-ci bot commented Jan 17, 2025

Resyntax fixed 50 issues in 20 files.

  • Fixed 12 occurrences of let-to-define
  • Fixed 12 occurrences of single-clause-match-to-match-define
  • Fixed 4 occurrences of define-lambda-to-define
  • Fixed 4 occurrences of cond-let-to-cond-define
  • Fixed 3 occurrences of if-else-false-to-and
  • Fixed 2 occurrences of nested-if-to-cond
  • Fixed 2 occurrences of map-to-for
  • Fixed 2 occurrences of cond-else-if-to-cond
  • Fixed 1 occurrence of quasiquote-to-list
  • Fixed 1 occurrence of define-simple-macro-to-define-syntax-parse-rule
  • Fixed 1 occurrence of for/fold-result-keyword
  • Fixed 1 occurrence of append*-and-map-to-append-map
  • Fixed 1 occurrence of equal-null-list-to-null-predicate
  • Fixed 1 occurrence of always-throwing-if-to-when
  • Fixed 1 occurrence of inverted-when
  • Fixed 1 occurrence of zero-comparison-to-negative?
  • Fixed 1 occurrence of syntax-disarm-migration

resyntax-ci bot added 19 commits January 17, 2025 00:31
The `define-simple-macro` form has been renamed to `define-syntax-parse-rule`.
The `null?` predicate can be used to test for the empty list.
Internal definitions are recommended instead of `let` expressions, to reduce nesting.
This `map` operation can be replaced with a `for/list` loop.
Internal definitions are recommended instead of `let` expressions, to reduce nesting.
This `match` expression can be simplified using `match-define`.
This `if` expression can be refactored to an equivalent expression using `and`.
The `define` form supports a shorthand for defining functions.
The `syntax-disarm` function is a legacy function that does nothing.
Only one of the `for/fold` expression's result values is used. Use the `#:result` keyword to return just that result.
The `append-map` function can be used to map each element into multiple elements in a single pass.
The `else`-`if` branch of this `cond` expression can be collapsed into the `cond` expression.
Using `when` and `unless` is simpler than a conditional with an always-throwing branch.
This quasiquotation is equialent to a simple `list` call.
This expression is equivalent to calling the `negative?` predicate.
This negated `when` expression can be replaced by an `unless` expression.
This `if` expression can be refactored to an equivalent expression using `and`.
Internal definitions are recommended instead of `let` expressions, to reduce nesting.
This `if`-`else` chain can be converted to a `cond` expression.
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.

0 participants