flycheck / flycheck-rust

Better Rust/Cargo support for Flycheck
GNU General Public License v3.0
121 stars 19 forks source link

Add support for 'required-features'. #69

Closed little-arhat closed 6 years ago

little-arhat commented 6 years ago

Discover 'required-features' in Cargo manifest and initialize value of 'rust-cargo-features'. Fixes #68.

little-arhat commented 6 years ago

@fmdkdd yeah, sure! Didn't want to add more code for tests without knowing it looks more or less ok %)

Thanks for comments, fixed.

little-arhat commented 6 years ago

Hm, tests are failing since cargo there doesn't have "required-features" in cargo metadata output. Should I modify test suite to compare against either alist with required-features or the old one?

fmdkdd commented 6 years ago

Shouldn't the nightly cargo already emit required-features? Looks like the cargo version is trailing behind:

cargo 1.29.0-nightly (6a7672ef5 2018-08-14)

The test will break for beta and stable, but should eventually get there. In the meantime, we should skip it for older versions. We can (signal 'buttercup-pending "requires cargo 1.29") to mark the test as pending. We could do that after inspecting cargo --version.

little-arhat commented 6 years ago

@fmdkdd yeah, it's lagging behind rustc, not sure what the actual release schedule cargo has. Anyways, it should hit nightly channel soon and then tests will pass for nightly. For other channels I've added check that disables tests for older cargos.

Thanks!

little-arhat commented 6 years ago

Apparently, cargo is not bumped automatically for nightly channel, but PR has been posted, so it should be available in next nighly!

@fmdkdd do you have any other comments I should address? %)

fmdkdd commented 6 years ago

Apparently, cargo is not bumped automatically for nightly channel,

Interesting! Thanks for keeping us posted.

do you have any other comments I should address?

Nope, LGTM. Good job and thank you for the contribution. :clap: