rust/rustfmt.toml

75 lines
2.7 KiB
TOML
Raw Normal View History

# Run rustfmt with this config (it should be picked up automatically).
version = "Two"
use_small_heuristics = "Max"
merge_derives = false
# by default we ignore everything in the repository
# tidy only checks files which are not ignored, each entry follows gitignore style
ignore = [
# tests for now are not formatted, as they are sometimes pretty-printing constrained
# (and generally rustfmt can move around comments in UI-testing incompatible ways)
"src/test",
# tidy issues (line length, etc.)
# to be fixed shortly
"src/libcore/iter/adapters/mod.rs",
"src/libcore/iter/traits/iterator.rs",
"src/librustc/hir/lowering.rs",
"src/librustc/infer/error_reporting/nice_region_error/outlives_closure.rs",
"src/librustc/lint/mod.rs",
"src/librustc/middle/resolve_lifetime.rs",
"src/librustc/traits/mod.rs",
"src/librustc/ty/constness.rs",
"src/librustc/ty/context.rs",
"src/librustc/ty/wf.rs",
"src/librustc_codegen_llvm/back/write.rs",
"src/librustc_codegen_llvm/consts.rs",
"src/librustc_codegen_llvm/debuginfo/metadata.rs",
"src/librustc_codegen_ssa/base.rs",
"src/librustc_codegen_ssa/mir/place.rs",
"src/librustc_codegen_utils/symbol_names/v0.rs",
"src/librustc_errors/emitter.rs",
"src/librustc_mir/borrow_check/diagnostics/mutability_errors.rs",
"src/librustc_mir/borrow_check/type_check/mod.rs",
"src/librustc_mir/build/expr/as_rvalue.rs",
"src/librustc_mir/build/matches/mod.rs",
"src/librustc_mir/build/mod.rs",
"src/librustc_mir/const_eval.rs",
"src/librustc_mir/interpret/place.rs",
"src/librustc_mir/monomorphize/collector.rs",
"src/librustc_passes/ast_validation.rs",
"src/librustc_resolve/lib.rs",
"src/librustc_resolve/resolve_imports.rs",
"src/librustc_typeck/astconv.rs",
"src/librustc_typeck/check/_match.rs",
"src/librustc_typeck/check/coercion.rs",
"src/librustc_typeck/check/method/confirm.rs",
"src/librustc_typeck/check/mod.rs",
"src/librustc_typeck/check/wfcheck.rs",
"src/librustdoc/html/markdown/tests.rs",
"src/libstd/sys/sgx/abi/mem.rs",
"src/libstd/sys/unix/os.rs",
"src/libsyntax_expand/parse/lexer/tests.rs",
"src/libsyntax_expand/parse/tests.rs",
"src/libsyntax_ext/test.rs",
"src/tools/build-manifest/src/main.rs",
"src/librustc_feature",
# do not format submodules
"src/doc/book",
"src/doc/edition-guide",
"src/doc/embedded-book",
"src/doc/nomicon",
"src/doc/reference",
"src/doc/rust-by-example",
"src/doc/rustc-guide",
"src/llvm-project",
"src/stdarch",
"src/tools/cargo",
"src/tools/clippy",
"src/tools/miri",
"src/tools/rls",
"src/tools/rust-installer",
"src/tools/rustfmt",
]