Add test cases for elaborated and completed class declarations.
Resolve the type of declarations with reference types.