feat: upgrade fink to v0.4.0 with WAT/CPS sourcemap sync#21
Merged
Conversation
- Upgrade fink crate from v0.3.0 to v0.4.0: - Replace closure_lifting::lift_all with lifting::lift - Switch from lower_expr to lower_module (correct entry for module-level CPS) - Add partial::apply before scopes in all pipelines (required by v0.4.0) - Add scopes::analyse for ScopeResult required by lower_module - Add SynthIdent arm to node_kind_label, serialize_children, collect_tokens - WAT panel: strip inline sourceMappingURL comment from displayed WAT text and parse it for source↔WAT cursor sync (highlight line on src cursor move) - Fix VLQ sourcemap decoder: unmapped stop-marker segments (1-field VLQ) must still advance the column accumulator — skipping them caused col positions to be 4 units low (e.g. cpsCol 30/32 instead of 34/41) - Fix CPS panel: clear source→CPS highlight decoration when clicking in CPS (was persisting after source-driven sync until next source cursor move) - Fix CPS tokenizer timing: call tokenizer.update() before model.setValue() so Monaco's re-tokenize pass sees the new tokens immediately - Add WAT syntax highlighting via hand-written Monarch tokenizer
WAT panel: - Fix VLQ decoder: unmapped stop-marker segments (1-field) must advance the column accumulator even though they emit no mapping entry — fixes col positions being off when stop markers precede mapped segments - Switch from whole-line to inline highlight decoration - Use s-expression paren matching to tightly bound the highlight span, falling back to next mapped col then end-of-line CPS panel: - Same VLQ decoder fix (1-field segments advance col accumulator) - Clear source→CPS highlight decoration when CPS cursor moves, so source-driven highlights don't persist after clicking into CPS
|
This PR will release v1.14.0 |
|
🎉 This PR is included in version 1.14.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
partial::apply → lower_module, replacinglower_exprandclosure_lifting::lift_allsourceMappingURLfrom displayed text and use it for source↔WAT cursor sync with tight s-expression span highlightingTest plan
foo = fn aa, bb:\n aa + bbin the source editoraa,bb,+,fooin source highlights the correct token in CPSaa,bb,+in source highlights the correct(local.get $xx)span in WAT (not the whole line)importkeyword