Skip to content

Fails to build with default-features = false #41

@palfrey

Description

@palfrey

These function imports should be gated behind their relevant feature flags

error[E0432]: unresolved imports `utils::digits_in_i64`, `utils::digits_in_usize`
  --> external/rules_rust++crate+crates__redis-protocol-6.0.0/src/lib.rs:66:17
   |
66 | pub use utils::{digits_in_i64, digits_in_usize, redis_keyslot, str_to_f64};
   |                 ^^^^^^^^^^^^^  ^^^^^^^^^^^^^^^ no `digits_in_usize` in `utils`
   |                 |
   |                 no `digits_in_i64` in `utils`
   |
note: found an item that was configured out
  --> external/rules_rust++crate+crates__redis-protocol-6.0.0/src/utils.rs:31:8
   |
31 | pub fn digits_in_i64(d: i64) -> usize {
   |        ^^^^^^^^^^^^^
note: the item is gated behind the `std` feature
  --> external/rules_rust++crate+crates__redis-protocol-6.0.0/src/utils.rs:30:7
   |
30 | #[cfg(feature = "std")]
   |       ^^^^^^^^^^^^^^^
note: found an item that was configured out
  --> external/rules_rust++crate+crates__redis-protocol-6.0.0/src/utils.rs:42:8
   |
42 | pub fn digits_in_i64(d: i64) -> usize {
   |        ^^^^^^^^^^^^^
note: the item is gated behind the `libm` feature
  --> external/rules_rust++crate+crates__redis-protocol-6.0.0/src/utils.rs:41:7
   |
41 | #[cfg(feature = "libm")]
   |       ^^^^^^^^^^^^^^^^
note: found an item that was configured out
  --> external/rules_rust++crate+crates__redis-protocol-6.0.0/src/utils.rs:11:8
   |
11 | pub fn digits_in_usize(d: usize) -> usize {
   |        ^^^^^^^^^^^^^^^
note: the item is gated behind the `std` feature
  --> external/rules_rust++crate+crates__redis-protocol-6.0.0/src/utils.rs:10:7
   |
10 | #[cfg(feature = "std")]
   |       ^^^^^^^^^^^^^^^
note: found an item that was configured out
  --> external/rules_rust++crate+crates__redis-protocol-6.0.0/src/utils.rs:21:8
   |
21 | pub fn digits_in_usize(d: usize) -> usize {
   |        ^^^^^^^^^^^^^^^
note: the item is gated behind the `libm` feature
  --> external/rules_rust++crate+crates__redis-protocol-6.0.0/src/utils.rs:20:7
   |
20 | #[cfg(feature = "libm")]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions