fix type operation implementation