Skip to content

Commit 4865293

Browse files
committed
Rust: reduce log-level of diagnostics when extracting library files
1 parent 3a9befd commit 4865293

File tree

1 file changed

+8
-0
lines changed
  • rust/extractor/src/translate

1 file changed

+8
-0
lines changed

rust/extractor/src/translate/base.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -210,6 +210,14 @@ impl<'a> Translator<'a> {
210210
full_message: String,
211211
location: (LineCol, LineCol),
212212
) {
213+
let severity = if self.source_kind == SourceKind::Library {
214+
match severity {
215+
DiagnosticSeverity::Error => DiagnosticSeverity::Info,
216+
_ => DiagnosticSeverity::Debug,
217+
}
218+
} else {
219+
severity
220+
};
213221
let (start, end) = location;
214222
dispatch_to_tracing!(
215223
severity,

0 commit comments

Comments
 (0)