Rework definition context rules
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 25/100
- Issue type
- Feature
- Clarity
- Needs clarification
- Activity status
- Stale
- Domain
- tooling
Research direction
Start with the define-definition-context-refactoring-rule entry point and review issue #476 to understand the replacement problems described here. Compare its current behavior with the Rhombus statement-macro model mentioned in the issue. Done would mean a decided and implemented approach that avoids requiring callers to manage replacement forms and no longer depends on hard-coded definition-context forms.
Written by the indexing model from the issue text.
Description
Creating a definition context rule with define-definition-context-refactoring-rule is somewhat awkward. There's a few usability issues:
- You have to match the entire definition context, which is rarely useful.
- You have to be careful to use
~replacement,~splicing-replacement, and~focus-replacement-onin order to avoid issues like #476. - The set of recognized definition context forms is hard-coded.
Something better should be possible. Perhaps something like how Rhombus macros work, where a statement macro can match on all following statements and statement macros return two values: an expansion and an "unprocessed tail". That would let Resyntax automatically use ~replacement, ~splicing-replacement, and ~focus-replacement-on, and it would remove the need for definition context rules to care about the forms earlier in the definition context.
- Dominant language
- Racket
- Stars
- 70
- Forks
- 11
- PR merge metrics
- No merged PRs in 30d
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from jackfirth/resyntax
-
documentation
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
documentation
Difficulty 4/5 3-5 days Newbie friendliness 45/100
-
testing
Difficulty 4/5 3-5 days Newbie friendliness 45/100
-
testing
Difficulty 3/5 1-2 days Newbie friendliness 75/100
-
testing
Difficulty 4/5 3-5 days Newbie friendliness 68/100
All issues in jackfirth/resyntax
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
idean3885/claude-ops-agent#521 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
0xMiden/bridge-portal#132 ·
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
newrelic-experimental/preflight#793 · 1 comment ·
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
babalae/bettergi-scripts-list#3674 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
caddyserver/caddy#8046 ·