rearranged types.h and fixed a conditional jump