Fixed errors and warnings associated with visible private types