mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-25 11:17:13 +00:00
Disable error log for position clamping, its too noisy due to ease of triggering
This commit is contained in:
parent
8d75311400
commit
5022fb6343
@ -40,12 +40,13 @@ pub(crate) fn offset(
|
|||||||
})?;
|
})?;
|
||||||
let col = TextSize::from(line_col.col);
|
let col = TextSize::from(line_col.col);
|
||||||
let clamped_len = col.min(line_range.len());
|
let clamped_len = col.min(line_range.len());
|
||||||
if clamped_len < col {
|
// FIXME: The cause for this is likely our request retrying. Commented out as this log is just too chatty and very easy to trigger.
|
||||||
tracing::error!(
|
// if clamped_len < col {
|
||||||
"Position {line_col:?} column exceeds line length {}, clamping it",
|
// tracing::error!(
|
||||||
u32::from(line_range.len()),
|
// "Position {line_col:?} column exceeds line length {}, clamping it",
|
||||||
);
|
// u32::from(line_range.len()),
|
||||||
}
|
// );
|
||||||
|
// }
|
||||||
Ok(line_range.start() + clamped_len)
|
Ok(line_range.start() + clamped_len)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user