apply the same technique to generate default and virtuals