diff options
| author | Nick Cameron <ncameron@mozilla.com> | 2014-09-05 17:10:32 +1200 |
|---|---|---|
| committer | Nick Cameron <ncameron@mozilla.com> | 2014-09-09 10:41:27 +1200 |
| commit | c2fcd4ca723426c9d708a4cc49da873124e44891 (patch) | |
| tree | 520409c83f25eafb56870265c02fa6536d0433ac /src/libcore | |
| parent | 0c73e5fc5f212d30bb46b96cb45b51251217a199 (diff) | |
Check traits for built-in bounds in impls
Diffstat (limited to 'src/libcore')
| -rw-r--r-- | src/libcore/ops.rs | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/libcore/ops.rs b/src/libcore/ops.rs index 836285bc313..94febf03635 100644 --- a/src/libcore/ops.rs +++ b/src/libcore/ops.rs @@ -55,6 +55,8 @@ * */ +use kinds::Sized; + /** * * The `Drop` trait is used to run some code when a value goes out of scope. This @@ -700,7 +702,7 @@ pub trait IndexMut<Index,Result> { * ``` */ #[lang="deref"] -pub trait Deref<Result> { +pub trait Deref<Sized? Result> { /// The method called to dereference a value fn deref<'a>(&'a self) -> &'a Result; } @@ -740,7 +742,7 @@ pub trait Deref<Result> { * ``` */ #[lang="deref_mut"] -pub trait DerefMut<Result>: Deref<Result> { +pub trait DerefMut<Sized? Result>: Deref<Result> { /// The method called to mutably dereference a value fn deref_mut<'a>(&'a mut self) -> &'a mut Result; } |
