Skip to content
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

Tracking Issue for RFC 3591: useing a function from a trait #134691

Open
4 tasks
clubby789 opened this issue Dec 23, 2024 · 1 comment
Open
4 tasks

Tracking Issue for RFC 3591: useing a function from a trait #134691

clubby789 opened this issue Dec 23, 2024 · 1 comment
Labels
B-RFC-approved Blocker: Approved by a merged RFC but not yet implemented. C-tracking-issue Category: An issue tracking the progress of sth. like the implementation of an RFC S-tracking-unimplemented Status: The feature has not been implemented. T-lang Relevant to the language team, which will review and decide on the PR/issue.

Comments

@clubby789
Copy link
Contributor

This is a tracking issue for the RFC "Add support for use Trait::func" (rust-lang/rfcs#3591).
The feature gate for the issue is #![feature(import_trait_associated_functions)].

About tracking issues

Tracking issues are used to record the overall progress of implementation.
They are also used as hubs connecting to other relevant issues, e.g., bugs or open design questions.
A tracking issue is however not meant for large scale discussion, questions, or bug reports about a feature.
Instead, open a dedicated issue for the specific matter and add the relevant feature gate label.
Discussion comments will get marked as off-topic or deleted.
Repeated discussions on the tracking issue may lead to the tracking issue getting locked.

Steps

Unresolved Questions

Implementation history

@clubby789 clubby789 added the C-tracking-issue Category: An issue tracking the progress of sth. like the implementation of an RFC label Dec 23, 2024
@fmease fmease added B-RFC-approved Blocker: Approved by a merged RFC but not yet implemented. T-lang Relevant to the language team, which will review and decide on the PR/issue. S-tracking-unimplemented Status: The feature has not been implemented. labels Dec 23, 2024
@crumblingstatue
Copy link
Contributor

crumblingstatue commented Dec 23, 2024

Might be worth noting that there is an orthogonal implementation of using a trait function through the unstable fn_delegation feature.

#![feature(fn_delegation)]

reuse Default::default;

fn main() {
    let s: i32 = default();
    dbg!(s);
}

Although my understanding is that this is just some kind of experiment, and will not be stabilized?
Might be worth taking a look at the implementation though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
B-RFC-approved Blocker: Approved by a merged RFC but not yet implemented. C-tracking-issue Category: An issue tracking the progress of sth. like the implementation of an RFC S-tracking-unimplemented Status: The feature has not been implemented. T-lang Relevant to the language team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

3 participants