Given the generic register
method below I would like to define the :=
operator as a symbolic alias.
def register[Prop <: Property[_]](prop: Prop): Prop
@inline
final def :=[Prop <: Property[_]] = register[Prop] _
最初,我想写这样的话:
val := = register _
但是,这给我带来了职能签名Nothing => no
。 我的下一个尝试是将其与“<代码>Prop”的类型联系起来,但显然只有在我将其编为“代码>def
Ideally I would like to omit the @inline
annotation but I am not sure what object code the Scala compiler makes out of it.
www.un.org/Depts/DGACM/index_spanish.htm 最重要的是我的目标,是不要有<条码>:=条码>方法重复<条码>所有部分的签字,但名称除外,然后简单地让前代表到后者。