fix problem with the creation of main types