made Rotor::encode in Assembly