TypeInference: truly fixed bug with inferredType