Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

orphan rules mermad diagram #158

Open
miguelraz opened this issue Aug 30, 2022 · 1 comment
Open

orphan rules mermad diagram #158

miguelraz opened this issue Aug 30, 2022 · 1 comment
Assignees

Comments

@miguelraz
Copy link
Contributor

miguelraz commented Aug 30, 2022

I read this article and I loved this diagram for the Orphan Rules - no reason we can't add a nice mermaid diagram for it:
https://www.shuttle.rs/blog/2022/07/28/patterns-with-rust-types

Pretyyyyyy

@miguelraz miguelraz self-assigned this Aug 30, 2022
@miguelraz
Copy link
Contributor Author

miguelraz commented Aug 31, 2022

I came up with this so far:

GitHub doesn't want to render my amazing emoji game >:(

flowchart TD
    A(Crate 1 fa:fa-box <br /> trait MyTrait <br />) & B(Crate 2 fa:fa-box <br /> struct MyStruct <br />)--> C(Crate 3 fa:fa-box <br /> impl MyTrait for MyStruct <br />) & D(Crate 4 fa:fa-box <br /> impl MyTrait for MyStruct <br />)
    C & D --> E(OurCrate ??? <br /> fa:fa-ban fa:fa-bomb fa:fa-ban fa:fa-bomb fa:fa-ban)
Loading

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant