summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorManos Pitsidianakis <manos@pitsidianak.is>2026-05-21 13:21:15 +0300
committerMiguel Ojeda <ojeda@kernel.org>2026-05-29 00:26:40 +0300
commit420dd187e1572bb7e232781bc4377a80c8eb64fb (patch)
treea3d752ef4fc446c1a3d139ca59caf304b5ce338d
parent2da76b814ec068e88d2260da5fa8575012227a5a (diff)
downloadlinux-420dd187e1572bb7e232781bc4377a80c8eb64fb.tar.xz
.gitignore: ignore rustc long type txt files
When rustc prints an error containing a long type that doesn't fit in a line, it will write the whole thing in a .txt file and print messages like: note: the full type name has been written to 'path/to/subsystem/module_name.long-type-11621316855315349594.txt' [ Depending on the compiler version and the kind of error, there are two possible spellings -- copying them here for reference: = note: the full name for the type has been written to '...long-type-...txt' = note: the full type name has been written to '...long-type-...txt' In addition, we could clean the files as well in one of our cleaning Make targets [1][2]. Another option would be `--verbose` (but it implies more things that we probably don't want) or `-Zwrite-long-types-to-disk=no` (unstable so far, but a possible alternative if we prefer to avoid the files and simply see the long types in the output -- I asked upstream Rust about it [3]). Link: https://lore.kernel.org/rust-for-linux/CANiq72=cKXdmxEacuGET8fuz_v5eFGB50vnOnKZZJd6iEeAAFA@mail.gmail.com/ [1] Link: https://github.com/Rust-for-Linux/linux/issues/1236 [2] Link: https://rust-lang.zulipchat.com/#narrow/channel/131828-t-compiler/topic/.60-Zwrite-long-types-to-disk.3Dno.60/near/598310194 [3] - Miguel ] Long types like core::result::Result<core::pin::Pin<Box<_, Kmalloc, kernel::error::Error>: pin_init::PinInit<Box<_, Kmalloc>, _> are common during development, so add a gitignore entry. Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is> Acked-by: Danilo Krummrich <dakr@kernel.org> Link: https://patch.msgid.link/20260521-rust-gitignore-long-types-txt-v1-1-5be5e6fa427c@pitsidianak.is [ Moved the lines closer to the existing rust-analyzer one. - Miguel ] Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
-rw-r--r--.gitignore3
1 files changed, 3 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore
index 3044b9590f05..f26eacf9b4a1 100644
--- a/.gitignore
+++ b/.gitignore
@@ -186,5 +186,8 @@ sphinx_*/
# Rust analyzer configuration
/rust-project.json
+# rustc error message long types
+*.long-type-*.txt
+
# bc language scripts (not LLVM bitcode)
!kernel/time/timeconst.bc