You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "jonahgao (via GitHub)" <gi...@apache.org> on 2024/02/20 03:19:24 UTC
[I] cargo-fmt cannot format modules declared inside macros [arrow-datafusion]
jonahgao opened a new issue, #9281:
URL: https://github.com/apache/arrow-datafusion/issues/9281
### Describe the bug
Found in #9271 and occurred in the 'datafusion-functions' crate.
`cargo-fmt` starts at the crate root and traverses submodules to find files, but it does not parse modules declared inside macros, thus files within these modules will not be processed. Additionally, only certain macros are exceptions, such as `cfg_if`.
Upstream issue: https://github.com/rust-lang/rustfmt/issues/3253
### To Reproduce
Run the shell commands under the repo directory.
```sh
rustfmt datafusion/functions/src/*/*.rs
git status
```
And here is also a minimal [repo](https://github.com/jonahgao/fmt-test/blob/master/src/mymod.rs) to reproduce it.
### Expected behavior
All rust files should be formatted.
### Additional context
_No response_
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] cargo-fmt cannot format modules declared inside macros [arrow-datafusion]
Posted by "alamb (via GitHub)" <gi...@apache.org>.
alamb commented on issue #9281:
URL: https://github.com/apache/arrow-datafusion/issues/9281#issuecomment-1966416799
here is a proposed fix: https://github.com/apache/arrow-datafusion/pull/9367
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] cargo-fmt cannot format modules declared inside macros [arrow-datafusion]
Posted by "alamb (via GitHub)" <gi...@apache.org>.
alamb closed issue #9281: cargo-fmt cannot format modules declared inside macros
URL: https://github.com/apache/arrow-datafusion/issues/9281
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org