Skip to content

Instantly share code, notes, and snippets.

@ALSchwalm
Created March 6, 2017 23:16
Show Gist options
  • Save ALSchwalm/a1acc010590aac091a4d0c968f6024a2 to your computer and use it in GitHub Desktop.
Save ALSchwalm/a1acc010590aac091a4d0c968f6024a2 to your computer and use it in GitHub Desktop.
let cat = Cat {
meow_factor: 7
purr_factor: 8
};
// No problem, a CloneMammal is impl for Cat
let clone_mammal: &CloneMammal = cat;
// Error!
let clone: &Clone = &clone_mammal;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment