Skip to content
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

Add no_std support and introduce feature std. #22

Merged
merged 3 commits into from
Jul 11, 2019

Conversation

0ndorio
Copy link
Contributor

@0ndorio 0ndorio commented Jul 7, 2019

This introduces no_std support and a new default feature called std. It also replaces skeptic as documentation testing dependency with the far more light weight doc_comment.

This has currently two known problems:

  1. During the doctest build step the following error message appears. It seems like this based on an doctest internal problem and has now further consequences as even after the message is printed all tests run properly (related: No global memory allocator error when testing no_std crate that does link to std rust-lang/rust#54010, liballoc doc tests are "silently" failing rust-lang/rust#52243).

       Doc-tests bendy
    error: no global memory allocator found but one is required; link to std or add #[global_allocator] to a    static item that implements the GlobalAlloc trait.
    
    error: aborting due to previous error
    
  2. As soon as doc_comment is used with the #[cfg(test)] attribute it is not working as expected and won't run the doc tests. I assume that the reason here is rustdoc not using the test flag (Revert "Set test flag when rustdoc is running with --test option"  rust-lang/rust#61199). So this will not work until Stabilize cfg(doc) rust-lang/rust#61351 and rustdoc: set cfg(doctest) when collecting doctests rust-lang/rust#62213 are merged and we change it into #[cfg(doctest)].

@0ndorio 0ndorio requested review from thequux and Delet0r July 8, 2019 08:54
@0ndorio 0ndorio merged commit faeb50f into P3KI:master Jul 11, 2019
@0ndorio 0ndorio deleted the feature/no_std_support branch July 11, 2019 16:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants