使用编译时反射在Scala中验证模块的全名

时间:2018-11-09 12:44:41

标签: scala scala-macros scala-reflect scala-macro-paradise

我想做的是在编译时使用宏注释获得Scala“对象”的全名(在反射API中也称为“模块”)。我无法使用运行时反射,因为我的目标是JavaScript运行时。

这是我现在拥有的当前宏实现:

Records which are unique in $ListLeft, comparing Name and Domain:

Name      Domain     SideIndicator
----      ------     -------------
NameLeft1 DomainLeft <=

Records which are unique in $ListRight, comparing Name and Domain:

Name       Domain      SideIndicator
----       ------      -------------
NameRight1 DomainRight =>

}

0 个答案:

没有答案