fix shifs of <32 bits
fix cast on final missing returns