Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign up`extra_requirement_in_impl` future-compatibility warning #37166
Comments
nikomatsakis
added
T-compiler
B-unstable
I-unsound 💥
A-metadata
metabug
and removed
I-unsound 💥
labels
Oct 14, 2016
nikomatsakis
added a commit
to nikomatsakis/rust
that referenced
this issue
Oct 14, 2016
nikomatsakis
added a commit
to nikomatsakis/rust
that referenced
this issue
Oct 14, 2016
nikomatsakis
added a commit
to nikomatsakis/rust
that referenced
this issue
Oct 19, 2016
nikomatsakis
added a commit
to nikomatsakis/rust
that referenced
this issue
Oct 21, 2016
nikomatsakis
added a commit
to nikomatsakis/rust
that referenced
this issue
Nov 1, 2016
keeperofdakeys
added a commit
to keeperofdakeys/rust
that referenced
this issue
Nov 5, 2016
keeperofdakeys
added a commit
to keeperofdakeys/rust
that referenced
this issue
Nov 6, 2016
This comment has been minimized.
This comment has been minimized.
|
There’s a desire to make this either a “lint-error” or “non-lint-warning” (can’t be disabled) for 1.16 and hard error for 1.17. |
This comment has been minimized.
This comment has been minimized.
|
Discussed in compiler-team meeting and decided to move this to deny-by-default. |
nagisa
added a commit
to nagisa/rust
that referenced
this issue
Jan 19, 2017
nagisa
referenced this issue
Jan 19, 2017
Merged
Deny extra_requirement_in_impl forward-compat lint #39195
alexcrichton
added a commit
to alexcrichton/rust
that referenced
this issue
Jan 19, 2017
J-F-Liu
added a commit
to J-F-Liu/pom
that referenced
this issue
Jan 20, 2017
alexcrichton
added a commit
to alexcrichton/rust
that referenced
this issue
Jan 20, 2017
This comment has been minimized.
This comment has been minimized.
|
This appears unrelated to metadata, untagging. |
Mark-Simulacrum
removed
the
A-metadata
label
May 13, 2017
Mark-Simulacrum
added
the
C-tracking-issue
label
Jul 22, 2017
This comment has been minimized.
This comment has been minimized.
|
@rfcbot fcp close It has been over a year since these future-compatibility warnings were issued. I move that we make this a HARD ERROR. This is a serious bug with real soundness implications and is currently set to error (deny) by default. Also, the backwards compatibility code happens to be getting in my way right now. =) |
This comment has been minimized.
This comment has been minimized.
rfcbot
commented
Nov 1, 2017
•
|
Team member @nikomatsakis has proposed to close this. The next step is review by the rest of the tagged teams:
No concerns currently listed. Once a majority of reviewers approve (and none object), this will enter its final comment period. If you spot a major issue that hasn't been raised at any point in this process, please speak up! See this document for info about what commands tagged team members can give me. |
rfcbot
added
the
proposed-final-comment-period
label
Nov 1, 2017
nikomatsakis
added a commit
to nikomatsakis/rust
that referenced
this issue
Nov 1, 2017
nikomatsakis
added a commit
to nikomatsakis/rust
that referenced
this issue
Nov 1, 2017
nikomatsakis
added a commit
to nikomatsakis/rust
that referenced
this issue
Nov 3, 2017
nikomatsakis
added a commit
to nikomatsakis/rust
that referenced
this issue
Nov 7, 2017
Nashenas88
added a commit
to Nashenas88/rust
that referenced
this issue
Nov 10, 2017
nikomatsakis
added a commit
to nikomatsakis/rust
that referenced
this issue
Nov 10, 2017
nikomatsakis
added a commit
to nikomatsakis/rust
that referenced
this issue
Nov 12, 2017
nikomatsakis
added a commit
to nikomatsakis/rust
that referenced
this issue
Nov 16, 2017
rfcbot
added
final-comment-period
and removed
proposed-final-comment-period
labels
Feb 16, 2018
This comment has been minimized.
This comment has been minimized.
rfcbot
commented
Feb 16, 2018
|
|
1 similar comment
This comment has been minimized.
This comment has been minimized.
rfcbot
commented
Feb 16, 2018
|
|
rfcbot
added
the
final-comment-period
label
Feb 16, 2018
This comment has been minimized.
This comment has been minimized.
rfcbot
commented
Feb 26, 2018
|
The final comment period is now complete. |
nikomatsakis
added
WG-compiler-traits
E-mentor
labels
Feb 27, 2018
This comment has been minimized.
This comment has been minimized.
|
It seems like this got done a long time ago. |
nikomatsakis commentedOct 14, 2016
•
edited
This is the summary issue for the
extra_requirement_in_implfuture-compatibility warning and other related errors. The goal of this page is describe why this change was made and how you can fix code that is affected by it. It also provides a place to ask questions or register a complaint if you feel the change should not be made. For more information on the policy around future-compatibility warnings, see our breaking change policy guidelines.What is the warning for?
There has been a longstanding bug in rustc (#18937) that sometimes allowed an impl
to place additional requirements on its methods above and beyond the requirements
that appear in the trait definition. For example:
This is unsound and can permit crashes and other arbitrary behavior.
The solution is usually to move the requirement into the trait definition:
or else remove the requirement from the impl.
When will this warning become a hard error?
At the beginning of each 6-week release cycle, the Rust compiler team will review the set of outstanding future compatibility warnings and nominate some of them for Final Comment Period. Toward the end of the cycle, we will review any comments and make a final determination whether to convert the warning into a hard error or remove it entirely.