Fix another generics bug with default methods. Closes #7295.

r?