Skip to content
Snippets Groups Projects
Commit 51238014 authored by bors's avatar bors
Browse files

Auto merge of #962 - glandium:dox, r=alexcrichton

Add dox::{Copy, Clone} impls for pointer and integer types.

Fixes: #961
parents 829d0203 e2bfbc5e
No related branches found
No related tags found
No related merge requests found
......@@ -19,6 +19,16 @@ mod imp {
fn clone(&self) -> Option<T> { loop {} }
}
impl<T> Copy for *mut T {}
impl<T> Clone for *mut T {
fn clone(&self) -> *mut T { loop {} }
}
impl<T> Copy for *const T {}
impl<T> Clone for *const T {
fn clone(&self) -> *const T { loop {} }
}
pub trait Clone {
fn clone(&self) -> Self;
}
......@@ -140,6 +150,10 @@ mod imp {
type Output = $i;
fn add(self, other: $i) -> $i { self + other }
}
impl Copy for $i {}
impl Clone for $i {
fn clone(&self) -> $i { loop {} }
}
)*)
}
each_int!(impl_traits);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment