-
Notifications
You must be signed in to change notification settings - Fork 101
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support formatting async/await code #27
Comments
Thanks for the bug report. I will take a look at it. But this feels like it should be handled by rustfmt similarly to cargo fmt. Do you know if this works with rust-mode ? |
Cargo fmt just adds the "--edition 2018" argument to all rustfmt calls:
The original rust-mode fails to format with the same error as rustic. |
Actually I found a workaround. You can create a .rustfmt.toml file and specify 2018 edition there. After that rustic auto format works again. See example rustfmt.toml file here - https://github.com/rust-lang/rustfmt/blob/master/rustfmt.toml |
Ok. Let's leave this issue open for others. |
I added a note in the readme. |
org babel: Add test for the popup case
Currently if you try to save async/await code you get a rustfmt error. In order to fix it you need to pass the argument "--edition 2018" to it (cargo fmt does it automatically). Unfortunately rustic dosen't allow to customize rustfmt options, only the binary path. Would be cool if there was a variable for customizing rustfmt options.
Thanks for your work, the mode is quite cool overall.
The text was updated successfully, but these errors were encountered: