I know about case classes, pattern matching, unapply and PartialFunction, but I'm confused about bellow macros snippet.
val declarations = weakTypeOf[T].declarations
val methods = declarations.collect { case m: MethodSymbol => m }
Scaladoc of MemberScope http://www.scala-lang.org/api/2.10.4/#scala.reflect.api.Scopes$MemberScope
Collect method accepts PartialFunction[Universe.Symbol, B]
I can't find unapply
method of MethodSymbol
and it's also trait not a case class, so in witch code compiler transforms
{ case m: MethodSymbol => m }