public function fixTypeInformation(ServiceDefinition $definition)
 {
     foreach ($definition->getAllTypes() as $type) {
         $phpType = $type->getPhpType();
         $xmlType = $type->getXmlType();
         if (null === $phpType) {
             throw new \InvalidArgumentException();
         }
         if (null === $xmlType) {
             $xmlType = $this->getXmlTypeMapping($phpType);
         }
         $type->setXmlType($xmlType);
     }
 }