This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import scala.tools.nsc.reporters._ | |
import scala.tools.nsc.Settings | |
import reflect.runtime.Mirror.ToolBox | |
object Test extends App { | |
// todo. compose the tree, equivalent to t5230, by hand | |
import scala.reflect.mirror._ | |
import scala.reflect.api._ | |
import scala.reflect.api.Modifier._ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Func<String, String> x = name => { | |
var buf = new StringBuilder(); | |
for (var i = 0; i < name.Length; ++i) { | |
var prev = i == 0 ? '\0' : name[i - 1]; | |
var curr = name[i]; | |
var next = i == name.Length - 1 ? '\0' : name[i + 1]; | |
if (Char.IsLower(prev) && Char.IsUpper(curr) && !Char.IsUpper(next)) { | |
buf.Append("-"); | |
buf.Append(Char.ToLower(curr)); | |
} else { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
error: recursive method factorial needs result type | |
Exception in thread "main" java.lang.Error: reflective compilation has failed | |
at scala.reflect.runtime.ToolBoxes$ToolBox$ToolBoxGlobal.runExpr(ToolBoxes.scala:95) | |
at scala.reflect.runtime.ToolBoxes$ToolBox.runExpr(ToolBoxes.scala:168) | |
at scala.reflect.runtime.ToolBoxes$ToolBox.runExpr(ToolBoxes.scala:171) | |
at Test$delayedInit$body.apply(t5274_0.scala:16) | |
at scala.Function0$class.apply$mcV$sp(Function0.scala:34) | |
at scala.runtime.AbstractFunction0.apply$mcV$sp(AbstractFunction0.scala:12) | |
at scala.App$$anonfun$main$1.apply(App.scala:61) | |
at scala.App$$anonfun$main$1.apply(App.scala:61) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import scala.tools.nsc.reporters._ | |
import scala.tools.nsc.Settings | |
import reflect.runtime.Mirror.ToolBox | |
object Test extends App { | |
val code = scala.reflect.Code.lift{ | |
class C | |
println(List(new C()).map(x => x).length) | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
object Foo extends App { | |
class C | |
println(List(new C()).map(x => x).length) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import scala.tools.nsc.reporters._ | |
import scala.tools.nsc.Settings | |
import reflect.runtime.Mirror.ToolBox | |
object Test extends App { | |
val code = scala.reflect.Code.lift{ | |
println(List(1).map(x => x).length) | |
}; | |
val reporter = new ConsoleReporter(new Settings) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
=== launch-scalac.bat === | |
@echo off | |
rem never ever use -Dscala.usejavacp=true here!! | |
java >con ^ | |
-classpath >con ^ | |
C:\Users\xeno.by\workspace\Kepler\lib\fjbg.jar;C:\Users\xeno.by\workspace\Kepler\lib\forkjoin.jar;C:\Users\xeno.by\workspace\Kepler\build\locker\classes\compiler;C:\Users\xeno.by\workspace\Kepler\build\locker\classes\library >con ^ | |
scala.tools.nsc.Main >con ^ | |
@d:\quicklib >con ^ | |
-Ydebug |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/build | |
/build/ | |
/target | |
/target/ | |
target/ | |
/dists/ | |
/out/ | |
/bin/ | |
/project/boot/ | |
/project/build/target/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
test\files\run\reify_anonymous.scala | |
test\files\run\reify_for1.scala | |
test\files\run\reify_generic1.scala | |
test\files\run\reify_generic2.scala | |
test\files\run\reify_getter.scala | |
test\files\run\reify_inheritance.scala | |
test\files\run\reify_printf.scala | |
test\files\run\reify_splices1.scala | |
test\files\run\reify_varargs.scala | |
test\files\run\t5230.scala |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<classpath> | |
<classpathentry kind="src" output="build/locker/classes/library" path="src/library"/> | |
<classpathentry kind="src" output="build/locker/classes/compiler" path="src/compiler"/> | |
<classpathentry kind="lib" path="lib/ant/ant-contrib.jar"/> | |
<classpathentry kind="lib" path="lib/ant/ant-dotnet-1.0.jar"/> | |
<classpathentry kind="lib" path="lib/ant/ant.jar"/> | |
<classpathentry kind="lib" path="lib/ant/maven-ant-tasks-2.1.1.jar"/> | |
<classpathentry kind="lib" path="lib/ant/vizant.jar"/> | |
<classpathentry kind="lib" path="lib/fjbg.jar"/> |
OlderNewer