SHARE
TWEET

Untitled

a guest Sep 17th, 2019 73 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. trait X {
  2.     const Y: i32;
  3. }
  4.  
  5. trait Z {
  6.     fn a() -> i32;
  7. }
  8.  
  9. struct B<T> {
  10.     t: std::marker::PhantomData<T>
  11. }
  12.  
  13. impl<T: X> Z for B<T> {
  14.     fn a() -> i32 {
  15.         const C: i32 = T::Y;
  16.  
  17.         C
  18.     }
  19. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top