Method call resolution for type parameters

The way method resolution works in Rust is specified in this section of the reference. For a given type T where a method is being called, it follows these steps: Start with a candidate list containing only T ( candidates := [T] ) Try to dereference ( * ) the last element of the list( last ) If *last is valid, add it to the list ( candidates := candidates : [last] ) and go to the previous step.…