Attempt to match types by their structure if they are from different ASTContexts,
rather than performing a pointer comparison only. When generating state for a
trace that uses multiple translation units (multiple MappedASTs), this allows
us to create a more logical state (otherwise it appears that pointers from one
translation unit to another are punned, even if they refer to the same type).