Slide 13
Slide 13 text
makeCallWithName: finding the name
Get the method that encloses the macro invocation.
Search the method body for a value definition whose right-hand side
is the macro invocation and return the name from that definition.
Otherwise, if the invocation computes the value of the method,
return the name of the method.
Otherwise, return the name of the macro.
If there is no enclosing method, get the enclosing template (class,
trait or object).
Search the template body for a value definition whose right-hand
side is the macro invocation.
Otherwise, report an error.