Exploring literal-level metaprogramming:
Assert(ScalaVersion() >= Version("2.11.0"))
def testExample() {
Compile {
if (ScalaVersion() < Version("2.11.1")) {
"oldFoo()"
} else {
"foo()"
}
}
}
Shunsuke Sogame <okomok@gmail.com>