Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Taking advantage of New Rust Features #558

Open
9 of 17 tasks
bluss opened this issue Nov 22, 2018 · 5 comments
Open
9 of 17 tasks

Taking advantage of New Rust Features #558

bluss opened this issue Nov 22, 2018 · 5 comments

Comments

@bluss
Copy link
Member

bluss commented Nov 22, 2018

Ideas and tracking to take advantage of “new” features in Rust

All features to be used because of what gain they give us, not to score points. Formulate goal & gain before implementing - and write it up the pull request 🙂.

#![cfg_attr(docsrs, feature(doc_cfg))]

and then on each item enabled by a specific feature, we add this:

#[cfg_attr(docsrs, doc(cfg(feature = "thefeature")))]

(For an example, see async_compression.)


Future features (not relevant yet, because they don't exist in stable Rust)


This is a tracking issue, please edit it.

@LukeMathWalker
Copy link
Member

It seems 2019 is indeed going to be the year of specialisation, const generics and GAT: rust-lang/rfcs#2657 🚀 🚀

@phungleson
Copy link

Hey mates, this looks like something that new person like me can help. Do you see any thing that is easy to get start with?

@max-sixty
Copy link
Contributor

Any thoughts on @phungleson 's question? CC @jturner314

Also the Run cargo fmt can be marked complete

@jturner314
Copy link
Member

Some suggestions:

  • Running cargo fix --edition-idioms and cleaning up the results.
  • Updating doc links to use rustdoc item links. (See RFC 1946, although not all of the RFC is implemented.)
  • Using NonZero (NonZero start #647).
  • Changing ArrayBase.ptr to NonNull. This would be a pretty extensive change that would touch lots of areas of the code base, but I think the changes would be relatively straightforward.
  • Seeing if it would be possible to replace the dependency on std with core and alloc.

@skewballfox
Copy link

looks like GATs are going to be part of stable next week

# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

No branches or pull requests

6 participants