sbdchd / neoformat

:sparkles: A (Neo)vim plugin for formatting code.
BSD 2-Clause "Simplified" License
1.98k stars 188 forks source link

[Question] How to get error? #429

Closed TornaxO7 closed 1 year ago

TornaxO7 commented 2 years ago

Hello! Currently I'm getting the following error message if I run :Neoformat rustfmt: image

Is it possible to get more information about the error?

bjornevik commented 2 years ago

Had a similar problem, got a better error message when using mhartington/formatter.nvim, for me it had something to do with rustfmt thinking the project was running rust 2015 edition.

Was able to fix by creating rustfmt.toml and putting edition = 2021 in it, after finding this.

Problem did not arise when running cargo fmt since rustfmt then has access to Cargo.toml and can check the rust edition.

TornaxO7 commented 1 year ago

Sorry for the late reply! Thank you for the information. Currently I'm not able to reproduce it anymore, so I'll close this for the time being.