trait
EmbeddedControls extends AnyRef
Value Members
-
final
def
!=(arg0: Any): Boolean
-
final
def
##(): Int
-
final
def
==(arg0: Any): Boolean
-
macro
def
__assign[T](lhs: T, rhs: T): Unit
-
macro
def
__doWhile(body: Unit, cond: Boolean): Unit
-
macro
def
__ifThenElse[T](cond: Boolean, thenBr: T, elseBr: T): T
-
macro
def
__lazyValDef[T](init: T): T
-
macro
def
__newVar[T](init: T): T
-
macro
def
__readVar[T](init: T): T
-
macro
def
__return(expr: Any): Nothing
-
macro
def
__valDef[T](init: T): T
-
macro
def
__whileDo(cond: Boolean, body: Unit): Unit
-
final
def
asInstanceOf[T0]: T0
-
def
clone(): AnyRef
-
final
def
eq(arg0: AnyRef): Boolean
-
def
equals(arg0: Any): Boolean
-
def
finalize(): Unit
-
final
def
getClass(): Class[_]
-
def
hashCode(): Int
-
macro
def
infix_!=(x1: Any, x2: Any): Boolean
-
macro
def
infix_##(x: Any): Int
-
macro
def
infix_==(x1: Any, x2: Any): Boolean
-
macro
def
infix_asInstanceOf[T](x: Any): T
-
macro
def
infix_clone(x: AnyRef): AnyRef
-
macro
def
infix_eq(x1: AnyRef, x2: AnyRef): Boolean
-
macro
def
infix_equals(x1: Any, x2: Any): Boolean
-
macro
def
infix_finalize(x: AnyRef): Unit
-
macro
def
infix_getClass(x: Any): Class[_]
-
macro
def
infix_hashCode(x: Any): Int
-
macro
def
infix_isInstanceOf[T](x: Any): Boolean
-
macro
def
infix_ne(x1: AnyRef, x2: AnyRef): Boolean
-
macro
def
infix_notify(x: AnyRef): Unit
-
macro
def
infix_notifyAll(x: AnyRef): Unit
-
macro
def
infix_synchronized[T](x: AnyRef, body: T): T
-
macro
def
infix_toString(x: Any): String
-
macro
def
infix_wait(x: AnyRef, timeout: Long, nanos: Int): Unit
-
macro
def
infix_wait(x: AnyRef, timeout: Long): Unit
-
macro
def
infix_wait(x: AnyRef): Unit
-
final
def
isInstanceOf[T0]: Boolean
-
final
def
ne(arg0: AnyRef): Boolean
-
final
def
notify(): Unit
-
final
def
notifyAll(): Unit
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
-
def
toString(): String
-
final
def
wait(): Unit
-
final
def
wait(arg0: Long, arg1: Int): Unit
-
final
def
wait(arg0: Long): Unit
Inherited from AnyRef
Inherited from Any
Default implementation of virtualized Scala control structures.
This trait is adapted from the
EmbeddedControlstrait in Scala Virtualized. See also https://raw.github.com/namin/scala/topic-virt/src/library/scala/EmbeddedControls.scalaThe
EmbeddedControlstrait provides method definitions where calls to the methods are treated by the compiler in a special way. The reason to express these calls as methods is to give embedded DSLs a chance to provide their own definitions and thereby override the standard interpretation of the compiler.Example: When faced with an
ifconstruct, the@virtualizedmacro annotation will generate a method call:ifThenElse(cond, thenp, elsep)This method call will be bound to an implementation based on normal rules of scoping. If it binds to the standard one in this trait, the corresponding macro will replace it by an
Iftree node. If not, the call will be left as it is and a staging or interpreting DSL can take over.None of the above will happen unless you annotate your code with
@virtualize.