Type-safe Linguistic Reflection