Skip to content

Instantly share code, notes, and snippets.

@rust-play
Created November 7, 2018 13:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rust-play/dc09cf51d30d50500826a7eea62bf1f6 to your computer and use it in GitHub Desktop.
Save rust-play/dc09cf51d30d50500826a7eea62bf1f6 to your computer and use it in GitHub Desktop.
Code shared from the Rust Playground
trait Rem {
type Output: ?Sized;
}
trait Float: Rem<Output = Self> { }
struct IeeeFloat;
impl Float for IeeeFloat { }
impl Rem for IeeeFloat
where Self: Float // elaborated to `where Self: Float, Self: Rem<Output = Self>`
{
type Output = IeeeFloat;
}
fn main() {
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment