-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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
trait objects of a fundamental trait are treated as fundamental types #56503
Labels
A-trait-system
Area: Trait system
T-lang
Relevant to the language team, which will review and decide on the PR/issue.
Comments
arielb1
added
A-trait-system
Area: Trait system
I-nominated
T-lang
Relevant to the language team, which will review and decide on the PR/issue.
labels
Dec 4, 2018
This should either be fixed ( |
Discussed in the @rust-lang/lang meeting. We decided that for now we should just make |
arielb1
added
the
E-mentor
Call for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.
label
Dec 14, 2018
No warning period needed because this is a nightly feature? I think I'll |
arielb1
removed
the
E-mentor
Call for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.
label
Dec 14, 2018
arielb1
added a commit
to arielb1/rust
that referenced
this issue
Dec 15, 2018
pietroalbini
added a commit
to pietroalbini/rust
that referenced
this issue
Dec 20, 2018
…matsakis stop treating trait objects from #[fundamental] traits as fundamental This is a [breaking-change] to code that exploits this functionality (which should be limited to code using `#![feature(fundamental)]`. Fixes rust-lang#56503. r? @nikomatsakis
Mark-Simulacrum
added a commit
to Mark-Simulacrum/rust
that referenced
this issue
Dec 21, 2018
…matsakis stop treating trait objects from #[fundamental] traits as fundamental This is a [breaking-change] to code that exploits this functionality (which should be limited to code using `#![feature(fundamental)]`. Fixes rust-lang#56503. r? @nikomatsakis
Centril
added a commit
to Centril/rust
that referenced
this issue
Dec 22, 2018
…matsakis stop treating trait objects from #[fundamental] traits as fundamental This is a [breaking-change] to code that exploits this functionality (which should be limited to code using `#![feature(fundamental)]`. Fixes rust-lang#56503. r? @nikomatsakis
bors
added a commit
that referenced
this issue
Dec 22, 2018
stop treating trait objects from #[fundamental] traits as fundamental This is a [breaking-change] to code that exploits this functionality (which should be limited to code using `#![feature(fundamental)]`. Fixes #56503. r? @nikomatsakis
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
A-trait-system
Area: Trait system
T-lang
Relevant to the language team, which will review and decide on the PR/issue.
I don't think this is intentional, at least it is not documented in the RFCs 1023 or 2451:
STR
Crate a (compile with
should_not_have_an_effect
):Crate b:
Expected Result
The
cfg_attr
does not have an effect - the code gives this error:Actual result
With
--cfg should_not_have_an_effect
, the code compilesStability consequences
This can't be observed in stable code right now - the only stable
#[fundamental]
traits areSized
(which doesn't have type parameters) and theFn
traits (which can only be implemented for tuples, and these are never fundamental). However, if we did stabilize a "normal"#[fundamental]
trait with type parameters, this would be visible on stable.The text was updated successfully, but these errors were encountered: