add lang conversions and remove dead code.