Optimize the GMetaTypedItemList::findByType method

Use a hash for the basetype retrieval.

This method is used to find the result type after each
method call (via fixupType) and also in fixUpHierarchy, taking O(n^2).

Valgrind reported ~76% of the time spent in this method for a sample
js program frequently invoking API through cpgf.