pub async fn handle_edit_insert_before(
name: &str,
code: &str,
client: &mut LspClient,
file_tracker: &mut FileTracker,
project_root: &Path,
dirty_files: &DirtyFiles,
) -> Result<Value>Expand description
Insert code before a symbol, skipping any leading attributes/decorators/doc comments.
Scans upward from the symbol’s start line to find #[...], @decorator,
or //////! doc comment lines, and inserts before those.
§Errors
Returns an error if the symbol can’t be found or the file can’t be written.