Q:

"Type mismatch" for function returning itself recursively

I have a function that returns a type of generic class K which extends the Comparable interface. This function calls itself recursively. Interestingly, when it gets called I receive the error Type mismatch: cannot convert from Comparable to K. 
public class NonEmptyTree<K extends Comparable<K>, V> implements Tree<K, V> {
    Tree right;
    K key;
    ...
    public K max() throws EmptyTreeException {
        try {
            return right.max(); // "Type mismatch: cannot convert from Comparable to K"
        } catch (EmptyTreeException e) {
            return key;
        }
    }
    ...
}

Changing the return statement to return (K) right.max(); removes the error and produces the expected behavior.
Why is the cast necessary and how can I produce the code such that does not require casting?

A:

The problem was in the declaration of right.
Rather than
Tree right;

It should be:
Tree<K, V> right;

