Don't call getMostRecentDecl when we know we have it.

On a Release build this takes the testcase in pr18055 from 0m3.892s to 0m1.452s.