Skip to content

libcore: Fix Sized bounds on overloaded function traits. #19573

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/libcore/ops.rs
Original file line number Diff line number Diff line change
Expand Up @@ -812,12 +812,12 @@ pub trait FnMut<Args,Result> for Sized? {

/// A version of the call operator that takes a by-value receiver.
#[lang="fn_once"]
pub trait FnOnce<Args,Result> for Sized? {
pub trait FnOnce<Args,Result> {
/// This is called when the call operator is used.
extern "rust-call" fn call_once(self, args: Args) -> Result;
}

impl<F,A,R> FnMut<A,R> for F
impl<Sized? F,A,R> FnMut<A,R> for F
where F : Fn<A,R>
{
extern "rust-call" fn call_mut(&mut self, args: A) -> R {
Expand Down