diff options
| author | Alex Crichton <alex@alexcrichton.com> | 2015-02-17 13:56:06 -0800 |
|---|---|---|
| committer | Alex Crichton <alex@alexcrichton.com> | 2015-02-17 13:56:06 -0800 |
| commit | 0cf2d00f0e034c8844bc9899b7e1df8c5eced60e (patch) | |
| tree | 504481ac7224bf0cc7fdccd2c2d154f3ddd5c5d7 /src/test | |
| parent | f1bb6c2f46f08c1d7b6d695f5b3cf93142cb8860 (diff) | |
| download | rust-0cf2d00f0e034c8844bc9899b7e1df8c5eced60e.tar.gz rust-0cf2d00f0e034c8844bc9899b7e1df8c5eced60e.zip | |
rustc: Track stability of trait implementations
Previously an implementation of a stable trait allows implementations of unstable methods. This updates the stability pass to ensure that all items of an impl block of a trait are indeed stable on the trait itself.
Diffstat (limited to 'src/test')
| -rw-r--r-- | src/test/compile-fail/lint-stability.rs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/test/compile-fail/lint-stability.rs b/src/test/compile-fail/lint-stability.rs index 5c187176fb2..f9cdfa4f7d6 100644 --- a/src/test/compile-fail/lint-stability.rs +++ b/src/test/compile-fail/lint-stability.rs @@ -133,6 +133,11 @@ mod cross_crate { impl UnstableTrait for S { } //~ WARNING use of unstable library feature trait LocalTrait : UnstableTrait { } //~ WARNING use of unstable library feature + + impl Trait for S { + fn trait_stable(&self) {} + fn trait_unstable(&self) {} //~ WARNING use of unstable library feature + } } mod inheritance { |
