Skip to content

lib.rs needs #![feature(no_std)] #1

Closed

Description

@mtnygard

Recent rust nightlies (at least as far back as 2015-11-19) require 'no_std' to be enabled as a feature before it can be used. Lacking that, the #![no_std] line results in a compile error:

/home/vagrant/.multirust/toolchains/nightly-2015-11-19/cargo/git/checkouts/multiboot2-elf64-151908bccf532495/master/src/lib.rs:1:1: 1:11 error: no_std is experimental (see issue #27701)
/home/vagrant/.multirust/toolchains/nightly-2015-11-19/cargo/git/checkouts/multiboot2-elf64-151908bccf532495/master/src/lib.rs:1 #![no_std]
                                                                                                                                 ^~~~~~~~~~
/home/vagrant/.multirust/toolchains/nightly-2015-11-19/cargo/git/checkouts/multiboot2-elf64-151908bccf532495/master/src/lib.rs:1:1: 1:11 help: add #![feature(no_std)] to the crate attributes to enable
error: aborting due to previous error
Could not compile `multiboot2`.

Activity

  1. phil-opp commented on Dec 31, 2015

    @phil-opp
    Member

    The no_std feature was stabilized in rust-lang/rust#30187. It is already stabilized in the current beta version and will work on 1.6 stable. So it should work fine on current nightlies.

  2. mtnygard commented on Dec 31, 2015

    @mtnygard
    Author

    Whoops. You're totally right. Confirmed that it works on current nightly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions