I have the following code:
case class Person(name: String, age: Int = 0)
def extractFieldNames[A](implicit m: Manifest[A]): Array[String] =
m.runtimeClass.getDeclaredFields.map(_.getName)
extractFieldNames[Person]
// should return Array("name", "age")
But what if I want to exclude age because of its default parameter? How would I do this?