Open Dushistov opened 7 years ago
For me, the big challenge is that IDEs would likely have multiple files open for edit that need to be checked and stdin wouldn't be sufficient. https://internals.rust-lang.org/t/jar-for-rust-single-file-crate-support-for-rustc/19576 does do some exploring for alternative ways for Cargo to communicate source buffers to rustc.
As I understand
cargo check
works only with files, so work pattern should looks like:cargo check
A lot of saves, bad for SSD.
So it would be good if
cargo check
provide interface like:cargo check --temp-file-name src/lib.rs
in such mode
cargo
read content of modifiedsrc/lib.rs
from stdin, and docargo check
assrc/lib.rs
contains data thatcargo
read from stdin.This helps for example flycheck-rust: https://github.com/flycheck/flycheck-rust/issues/29