codechain icon indicating copy to clipboard operation
codechain copied to clipboard

Use stable version of rustfmt/clippy

Open foriequal0 opened this issue 6 years ago • 2 comments

We currently use ruftfmt and clippy with a toolchain nightly-2019-05-17. But the stable version have caught up to our last nightly version.

nightly nightly-05-17: rustfmt 1.2.2-nightly (5274b49 2019-04-24) clippy 0.0.212 (ad3269c 2019-05-14)

stable 1.36: rustfmt 1.2.2-stable (5274b49 2019-04-24) clippy 0.0.212 (082cfa7 2019-06-07)

We might update our nightly toolchain version, or just stick with the stable version. I think the latter is better. It works well with the existing ecosystem (eg. IntelliJ) and requires less attention to keep up with recent version.

foriequal0 avatar Jul 30 '19 07:07 foriequal0

Urgh... we use many unstable features. Isn't it almost all flags in https://github.com/CodeChain-io/codechain/blob/master/rustfmt.toml ?

Warning: can't set `indent_style = Block`, unstable features are only available in nightly channel.
Warning: can't set `wrap_comments = false`, unstable features are only available in nightly channel.
Warning: can't set `comment_width = 120`, unstable features are only available in nightly channel.
Warning: can't set `normalize_comments = false`, unstable features are only available in nightly channel.
Warning: can't set `normalize_doc_attributes = true`, unstable features are only available in nightly channel.
Warning: can't set `format_strings = false`, unstable features are only available in nightly channel.
Warning: can't set `format_macro_matchers = false`, unstable features are only available in nightly channel.
Warning: can't set `format_macro_bodies = true`, unstable features are only available in nightly channel.
Warning: can't set `empty_item_single_line = true`, unstable features are only available in nightly channel.
Warning: can't set `fn_single_line = false`, unstable features are only available in nightly channel.
Warning: can't set `imports_indent = Block`, unstable features are only available in nightly channel.
Warning: can't set `imports_layout = Mixed`, unstable features are only available in nightly channel.
Warning: can't set `merge_imports = false`, unstable features are only available in nightly channel.
Warning: can't set `space_before_colon = false`, unstable features are only available in nightly channel.
Warning: can't set `space_after_colon = true`, unstable features are only available in nightly channel.
Warning: can't set `spaces_around_ranges = false`, unstable features are only available in nightly channel.
Warning: can't set `binop_separator = Front`, unstable features are only available in nightly channel.
Warning: can't set `overflow_delimited_expr = true`, unstable features are only available in nightly channel.
Warning: can't set `struct_field_align_threshold = 0`, unstable features are only available in nightly channel.
Warning: can't set `enum_discrim_align_threshold = 0`, unstable features are only available in nightly channel.
Warning: can't set `match_arm_blocks = true`, unstable features are only available in nightly channel.
Warning: can't set `fn_args_density = Tall`, unstable features are only available in nightly channel.
Warning: can't set `brace_style = PreferSameLine`, unstable features are only available in nightly channel.
Warning: can't set `control_brace_style = AlwaysSameLine`, unstable features are only available in nightly channel.
Warning: can't set `trailing_semicolon = false`, unstable features are only available in nightly channel.
Warning: can't set `trailing_comma = Vertical`, unstable features are only available in nightly channel.
Warning: can't set `match_block_trailing_comma = false`, unstable features are only available in nightly channel.
Warning: can't set `blank_lines_upper_bound = 2`, unstable features are only available in nightly channel.
Warning: can't set `blank_lines_lower_bound = 0`, unstable features are only available in nightly channel.
Warning: can't set `inline_attribute_width = 0`, unstable features are only available in nightly channel.
Warning: can't set `condense_wildcard_suffixes = true`, unstable features are only available in nightly channel.
Warning: can't set `color = Always`, unstable features are only available in nightly channel.
Warning: can't set `unstable_features = false`, unstable features are only available in nightly channel.
Warning: can't set `hide_parse_errors = false`, unstable features are only available in nightly channel.
Warning: can't set `error_on_line_overflow = false`, unstable features are only available in nightly channel.
Warning: can't set `indent_style = Block`, unstable features are only available in nightly channel.
Warning: can't set `wrap_comments = false`, unstable features are only available in nightly channel.
Warning: can't set `comment_width = 120`, unstable features are only available in nightly channel.
Warning: can't set `normalize_comments = false`, unstable features are only available in nightly channel.
Warning: can't set `normalize_doc_attributes = true`, unstable features are only available in nightly channel.
Warning: can't set `format_strings = false`, unstable features are only available in nightly channel.
Warning: can't set `format_macro_matchers = false`, unstable features are only available in nightly channel.
Warning: can't set `format_macro_bodies = true`, unstable features are only available in nightly channel.
Warning: can't set `empty_item_single_line = true`, unstable features are only available in nightly channel.
Warning: can't set `fn_single_line = false`, unstable features are only available in nightly channel.
Warning: can't set `imports_indent = Block`, unstable features are only available in nightly channel.
Warning: can't set `imports_layout = Mixed`, unstable features are only available in nightly channel.
Warning: can't set `merge_imports = false`, unstable features are only available in nightly channel.
Warning: can't set `space_before_colon = false`, unstable features are only available in nightly channel.
Warning: can't set `space_after_colon = true`, unstable features are only available in nightly channel.
Warning: can't set `spaces_around_ranges = false`, unstable features are only available in nightly channel.
Warning: can't set `binop_separator = Front`, unstable features are only available in nightly channel.
Warning: can't set `overflow_delimited_expr = true`, unstable features are only available in nightly channel.
Warning: can't set `struct_field_align_threshold = 0`, unstable features are only available in nightly channel.
Warning: can't set `enum_discrim_align_threshold = 0`, unstable features are only available in nightly channel.
Warning: can't set `match_arm_blocks = true`, unstable features are only available in nightly channel.
Warning: can't set `fn_args_density = Tall`, unstable features are only available in nightly channel.
Warning: can't set `brace_style = PreferSameLine`, unstable features are only available in nightly channel.
Warning: can't set `control_brace_style = AlwaysSameLine`, unstable features are only available in nightly channel.
Warning: can't set `trailing_semicolon = false`, unstable features are only available in nightly channel.
Warning: can't set `trailing_comma = Vertical`, unstable features are only available in nightly channel.
Warning: can't set `match_block_trailing_comma = false`, unstable features are only available in nightly channel.
Warning: can't set `blank_lines_upper_bound = 2`, unstable features are only available in nightly channel.
Warning: can't set `blank_lines_lower_bound = 0`, unstable features are only available in nightly channel.
Warning: can't set `inline_attribute_width = 0`, unstable features are only available in nightly channel.
Warning: can't set `condense_wildcard_suffixes = true`, unstable features are only available in nightly channel.
Warning: can't set `color = Always`, unstable features are only available in nightly channel.
Warning: can't set `unstable_features = false`, unstable features are only available in nightly channel.
Warning: can't set `hide_parse_errors = false`, unstable features are only available in nightly channel.
Warning: can't set `error_on_line_overflow = false`, unstable features are only available in nightly channel.

foriequal0 avatar Jul 30 '19 07:07 foriequal0

We can use stable clippy. +edit: No. We use unstable features in rlp bench code...

foriequal0 avatar Jul 30 '19 07:07 foriequal0