Hacker News new | past | comments | ask | show | jobs | submit login

`.` only produces a reference if you explicitly reference the result.

`a.b` is of type `B`, only `&a.b` is `&B` and `&mut a.b` is `&mut B`. This is unlike your proposal of `->` where `a->b` would be `*const B`.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: