Skip to content

feat: helpers to log on declaration names#1734

Open
thorimur wants to merge 4 commits intoleanprover-community:mainfrom
thorimur:declRef
Open

feat: helpers to log on declaration names#1734
thorimur wants to merge 4 commits intoleanprover-community:mainfrom
thorimur:declRef

Conversation

@thorimur
Copy link
Copy Markdown
Contributor

This PR bridges the gap between the declaration ranges stored in the DeclarationRange extension (used for e.g. go-to-def) and Syntax position info that can be used to log messages interactively.

Specifically, it introduces DeclarationRange.toSyntaxRange, findDeclarationSyntaxRange?, and withDeclRef?. The latter two ensure that the constant is not imported before constructing position info.

@github-actions github-actions bot added the awaiting-review This PR is ready for review; the author thinks it is ready to be merged. label Mar 26, 2026
mathlib-nightly-testing bot added a commit to leanprover-community/mathlib4-nightly-testing that referenced this pull request Mar 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting-review This PR is ready for review; the author thinks it is ready to be merged.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant