# Is \`ref\` more powerful than match ergonomics?

**URL:** <https://internals.rust-lang.org/t/is-ref-more-powerful-than-match-ergonomics/12111>\
**Category:** language design\
**Created:** [April 8, 2020, 8:48am UTC](https://internals.rust-lang.org/t/is-ref-more-powerful-than-match-ergonomics/12111 "2020-04-08T08:48:20Z")\
**Posts on this page:** 1\
**Showing post:** 66

<div class="post-metadata">

**Author:** ![tspiteri](https://sea2.discourse-cdn.com/flex002/user_avatar/internals.rust-lang.org/tspiteri/32/7283_2.png) [@tspiteri](https://internals.rust-lang.org/u/tspiteri)\
**Post date:** [April 29, 2020, 2:59am UTC](https://internals.rust-lang.org/t/is-ref-more-powerful-than-match-ergonomics/12111/66 "2020-04-29T02:59:49Z")

</div>

> [@RalfJung](#):
>
> (I am aware, but this is an unobservable implementation detail of rustc: a macro desugaring `+` to `Add::add` _does_ have the correct behavior.)

But it is observable through constness: traits cannot be used in const while primitive addition can be.

---

_[View the full topic](https://internals.rust-lang.org/t/is-ref-more-powerful-than-match-ergonomics/12111)._
