Skip to content

Regression because of #26008 #26096

Closed
Closed
@tomaka

Description

@tomaka

#26008 caused a regression (see travis).

Here is the code:

use std::rc::Rc;

let a: Rc<Option<u32>> = Rc::new(Some(5));
let _b: Option<&u32> = a.as_ref();

It works with stable because as_ref() is called on the Option.
But in the nightlies, as_ref() is called on the Rc and I get a &Option<u32> instead of a Option<&u32>.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P-highHigh priorityT-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions