Skip to content

Instantly share code, notes, and snippets.

@travisbrown
Created January 17, 2013 00:40
Show Gist options
  • Save travisbrown/4552471 to your computer and use it in GitHub Desktop.
Save travisbrown/4552471 to your computer and use it in GitHub Desktop.
trait ReflectionUtils {
def constructor(u: scala.reflect.api.Universe) = {
import u._
DefDef(
Modifiers(),
nme.CONSTRUCTOR,
Nil,
Nil :: Nil,
TypeTree(),
Block(
Apply(
Select(Super(This(tpnme.EMPTY), tpnme.EMPTY), nme.CONSTRUCTOR),
Nil
)
)
)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment