Skip to content

Using crates.io libc triggers unstable libc warning #21771

Closed
@SSheldon

Description

@SSheldon

With the crates.io distribution of libc (#20606) in my Cargo.toml:

[dependencies]
libc = "0.1"

I still get a warning on extern crate libc:

lib.rs:6:1: 6:19 warning: use of unstable library feature 'libc'
lib.rs:6 extern crate libc;
         ^~~~~~~~~~~~~~~~~~
lib.rs:6:1: 6:19 help: add #![feature(libc)] to the crate attributes to silence this warning
lib.rs:6 extern crate libc;
         ^~~~~~~~~~~~~~~~~~

Am I linking to the wrong crate? How do you choose the version from cargo over the version included in rustc?

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