improve exec and set methods