Skip to content

Method as_slice may be added to the standard library #3795

Description

@fabaff

Is your feature request related to a problem? Please describe.

Get rid of the warning that tell the method with that name may be added to the standard library in the future.

....
   Compiling bincode v2.0.1
   Compiling libafl_targets v0.15.4 (/build/source/crates/libafl_targets)
error: a method with this name may be added to the standard library in the future
   --> crates/libafl/src/executors/forkserver.rs:831:40
    |
831 |                 .copy_from_slice(input.as_slice());
    |                                        ^^^^^^^^
    |
    = warning: once this associated item is added to the standard library, the ambiguity may cause an error or change in behavior!
    = note: for more information, see issue #48919 <https://github.com/rust-lang/rust/issues/48919>
    = help: call with fully qualified syntax `libafl_bolts::AsSlice::as_slice(...)` to keep using the current method
    = note: `-D unstable-name-collisions` implied by `-D warnings`
    = help: to override `-D warnings` add `#[allow(unstable_name_collisions)]`

Describe the solution you'd like

Fixing the source instead of using the alternative 😉

Describe alternatives you've considered

Using -A unstable-name-collisions to suppress the warning.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions