You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add position/range conversion infrastructure for multi-document support
Introduce new infrastructure to support converting positions and ranges
for documents that may map to multiple URIs (like notebook cells):
- Add Db trait with document() and notebook_document() queries
- Provides access to document metadata needed for conversion
- notebook_document() returns notebook info for a file if it exists
- Add LspRange and LspPosition types for deferred LSP conversion
- Stores file, offset/range, db reference, and encoding
- Allows callers to choose conversion strategy:
* to_local_range()/to_local_position(): For use within same document/cell
* to_location(): For cross-document references with URI
- Critical for notebooks where one file maps to multiple cell URIs
- Update conversion traits (RangeExt, PositionExt, etc.)
- Add methods to create LspRange/LspPosition from internal types
- Support both notebook cells and regular files
This infrastructure prepares the codebase for notebook support where
position/range conversions must account for cell boundaries and URIs.
0 commit comments