Google News
logo
Rust - Interview Questions
Explain the significance of deref coercion and its functioning?
It is handy coercion that that is used for automatically converting into the reference to the content from the reference to the pointer.

Some examples of deref coercion are :

* ü &Box to &T
* &String to &str
* ü &Vec to &[T]
* ü &Arc to &T
* ü &Rc to &TW
Advertisement