Two canonical examples for specialization:
- Function1
- Tuple2
Specializing Function1
is a lot easier because functions do not have specialized fields.
Description Resource Path Location Type | |
object TypeParameterElementInfo is not a member of package org.eclipse.jdt.internal.core ScalaElements.scala /org.scala-ide.sdt.core/src/scala/tools/eclipse/javaelements line 13 Scala Problem | |
not found: type JavaElement ScalaElements.scala /org.scala-ide.sdt.core/src/scala/tools/eclipse/javaelements line 27 Scala Problem | |
object SourceField is not a member of package org.eclipse.jdt.internal.core ScalaElements.scala /org.scala-ide.sdt.core/src/scala/tools/eclipse/javaelements line 13 Scala Problem | |
object SourceFieldElementInfo is not a member of package org.eclipse.jdt.internal.core ScalaElements.scala /org.scala-ide.sdt.core/src/scala/tools/eclipse/javaelements line 13 Scala Problem | |
object SourceMethod is not a member of package org.eclipse.jdt.internal.core ScalaElements.scala /org.scala-ide.sdt.core/src/scala/tools/eclipse/javaelements line 13 Scala Problem | |
object SourceMethodElementInfo is not a member of package org.eclipse.jdt.internal.core ScalaElements.scala /or |
val input = Stream.continually(Console.readLine).takeWhile(_ != null) | |
val parsed = input.map(_.trim.split("\\s+").toSeq) | |
//parsed.take(100).foreach(println) | |
/** see CSS definition */ | |
def color(hash: Int): String = { | |
val hashAbs = math.abs(hash) | |
val colors = Seq("primary", "secondary-a", "secondary-b", "complement") |
Grzegorzs-MacBook-Pro:scala grek (2.10.x)$ awk -v startTime=5560684 -v duration=334546 '($1 >= startTime && $1 < startTime+duration) { print }' quick-lib-timings | |
5561559 289 scala.collection.Parallelizable.seq source-/Users/grek/scala/scala/src/library/scala/collection/Parallelizable.scala,line-22,offset=1019 | |
5562035 484 scala.collection.parallel.ParIterableLike.Repr source-/Users/grek/scala/scala/src/library/scala/collection/parallel/ParIterableLike.scala,line-156,offset=7465 | |
5562571 281 scala.collection.GenTraversableOnce.seq source-/Users/grek/scala/scala/src/library/scala/collection/GenTraversableOnce.scala,line-55,offset=1980 | |
5561401 1893 scala.collection.parallel.ParIterableLike.seq source-/Users/grek/scala/scala/src/library/scala/collection/parallel/ParIterableLike.scala,line-205,offset=9512 | |
5564180 |
// release-against-scala-milestone v0.1 | |
// ALTERED SETTINGS START | |
scalaVersion := "2.11.0-M1" | |
// disable cross building completely for releasing against milestones | |
crossScalaVersions := Seq.empty | |
scalaBinaryVersion in Global <<= scalaVersion.identity |
$ cat Foo.scala | |
object test3 { | |
trait A; trait C | |
trait B { self: A with C => | |
class Inner { | |
def b = B.this | |
} | |
} | |
} |
#!/bin/sh | |
BASE=$HOME/git/xsbt/ | |
for SRC in `find $BASE -not -path '*/src*/*' -name '*.scala'`;do | |
PKG=`grep "^\s*package " $SRC | perl -pse 's/\s*package\s*(\w*?)\b/package $1/' | tr -d '\r' | tr -d ';' | cut -d' ' -f2 | tr '\n.' '//'` | |
mkdir -p `dirname $SRC`/src/main/scala/$PKG | |
ln -s $SRC `dirname $SRC`/src/main/scala/$PKG`basename $SRC` | |
done |
strap.clean: | |
pack.clean: | |
init.jars.check: | |
init.jars: | |
init.maven.tasks: |
Possible compiler crash during test of: /Users/grek/scala/scala/test/files/pos/t5957 | |
java.lang.AssertionError: assertion failed: | |
while compiling: /Users/grek/scala/scala/test/files/pos/t5957/T_1.scala | |
during phase: jvm | |
library version: version 2.10.0-20120719-133117-f18ef37c66 | |
compiler version: version 2.10.0-20120719-133117-f18ef37c66 | |
reconstructed args: -deprecation -d /Users/grek/scala/scala/test/files/pos/t5957-pos.obj -classpath /Users/grek/scala/scala/test/files/codelib/code.jar:/Users/grek/scala/scala/build/pack/lib/scala-library.jar:/Users/grek/scala/scala/test/files/pos/t5957-pos.obj:/Users/grek/scala/scala/test/files/pos/t5957:/Users/grek/scala/scala/build/pack/lib/scala-compiler.jar:/Users/grek/scala/scala/build/pack/lib/scala-reflect.jar:/Users/grek/scala/scala/build/pack/lib/scala-library.jar:/Users/grek/scala/scala/build/pack/lib/scala-partest.jar:/Users/grek/scala/scala/lib/fjbg.jar:/Users/grek/scala/scala/build/pack/lib/scalap.jar:/Users/grek/scala/scala/build/pack/lib |
mac-grek:codwh grek (master)$ ./network_test.sh 10 7 queries/q7.ascii | |
RUNNING:./src/worker 1 2001 localhost:2000 localhost:2001 localhost:2002 localhost:2003 localhost:2004 localhost:2005 localhost:2006 localhost:2007 localhost:2008 localhost:2009 7 & | |
WARNING: New server, query id = 7 | |
Awaiting for a job | |
RUNNING:./src/worker 2 2002 localhost:2000 localhost:2001 localhost:2002 localhost:2003 localhost:2004 localhost:2005 localhost:2006 localhost:2007 localhost:2008 localhost:2009 7 & | |
RUNNING:./src/worker 3 2003 localhost:2000 localhost:2001 localhost:2002 localhost:2003 localhost:2004 localhost:2005 localhost:2006 localhost:2007 localhost:2008 localhost:2009 7 & | |
WARNING: New server, query id = 7 | |
Awaiting for a job | |
RUNNING:./src/worker 4 2004 localhost:2000 localhost:2001 localhost:2002 localhost:2003 localhost:2004 localhost:2005 localhost:2006 localhost:2007 localhost:2008 localhost:2009 7 & | |
WARNING: New server, query id = 7 |