I would find the following a little more palatable:

```scala
val ddefReset = resetLocalAttrs(ddef.duplicate)
// having defs here is important to make sure that there's no sneaky tree sharing in methods
// with multiple default parameters
def rtparams = ddefReset.tparams.map(_.duplicate)
def rtparams = ddefReset. vparamss.map(_.duplicate)
```