rustfmt.toml 630 B

123456789101112131415161718192021
  1. # Uses 2018 for maximum compatibiilty with Solana.
  2. edition = "2018"
  3. # Merge similar crates together to avoid multiple use statements.
  4. imports_granularity = "Module"
  5. # Consistency in formatting makes tool based searching/editing better.
  6. empty_item_single_line = false
  7. # Easier editing when arbitrary mixed use statements do not collapse.
  8. imports_layout = "Vertical"
  9. # Default rustfmt formatting of match arms with branches is awful.
  10. match_arm_leading_pipes = "Preserve"
  11. # Align Fields
  12. enum_discrim_align_threshold = 80
  13. struct_field_align_threshold = 80
  14. # Allow up to two blank lines for grouping.
  15. blank_lines_upper_bound = 2