This file has been truncated, but you can view the full file.
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
miles@tarski:perf_tester (topic/miles-byname-implicits)% java -jar target/scala-2.12/perf_tester-assembly-0.1.jar -s /home/miles/projects/scala -r results -a corpus/scala-library -c miles-byname-implicits --user miles -i 50 -p 3 | |
Output logging to /home/miles/projects/perf_tester/results/miles/miles-byname-implicits | |
ALL | |
Run Name Cycle samples Wall time (ms) All Wall time (ms) CPU(ms) Idle time (ms) Allocated(MBs) | |
pre-pr 1 50 9,332.00 [-10.92% +203.33%] 9,332.00 [-10.92% +203.33%] 9,188.06 [-10.64% +196.26%] 0.00 [ NaN% NaN%] 2,743.61 [-0.38% +6.58%] | |
pre-pr 2 50 9,088.94 [-10.42% +192.67%] 9,088.94 [-10.42% +192.67%] 8,959.18 [-10.03% +185.47%] 0.00 [ NaN% NaN%] 2,745.65 [-0.51% +6.81%] | |
pre-pr 3 50 9,176.00 [-9.87% +199.00%] 9,176.00 [-9.87% |
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
----------------------------- | |
ALL | |
Run Name Cycle samples Wall time (ms) All Wall time (ms) CPU(ms) Idle time (ms) Allocated(MBs) | |
pre-pr 1 30 9,830.23 [-13.87% +183.84%] 9,830.23 [-13.87% +183.84%] 9,644.07 [-13.42% +178.31%] 0.00 [ NaN% NaN%] 2,775.16 [-0.65% +6.12%] | |
pr 1 30 9,818.50 [-14.81% +186.90%] 9,818.50 [-14.81% +186.90%] 9,642.10 [-14.13% +181.26%] 0.00 [ NaN% NaN%] 2,762.69 [-0.67% +7.13%] | |
jason-feedback 1 30 9,805.13 [-14.34% +184.80%] 9,805.13 [-14.34% +184.80%] 9,617.57 [-13.61% +179.12%] 0.00 [ NaN% NaN%] 2,760.19 [-0.62% +6.94%] | |
----------------------------- | |
ALL | |
Run Name Cycle samples Wall time (ms) All Wall time (ms) CPU(ms) |
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.language.higherKinds | |
// Whitebox ... | |
trait Schema[T, R] { | |
def conv(t: T): R | |
} | |
object Schema { | |
// Whitebox macro: R is computed from T | |
implicit def mkSchema[T, R]: Schema[T, R] = ??? // macro ... |
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
// Current Scala 2 | |
trait Concat[A, B] { | |
type Result | |
def apply(a: A, b: B): Result | |
} | |
object Concat { | |
def apply[A, B](a: A, b: B)(implicit cab: Concat[A, B]): cab.Result = cab(a, b) | |
implicit def hnil[B]: Concat[HNil, B] { type Result = B } = new Concat[HNil, B] { |
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.language.{ higherKinds, implicitConversions } | |
object Defns { | |
type Id[T] = T | |
type ApplyTo[T] = { type λ[F[_]] = F[T] } | |
type Const1[T] = { type λ[F[_]] = T } | |
// Natural transform | |
trait ~>[F[_], G[_]] { | |
def apply[T](ft: F[T]): G[T] |
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
// What output does this yield? What should it? (try with either 2.12.x or 2.13.x) | |
// (spoiler: https://github.com/scala/bug/issues/10788) | |
object Test { | |
class Box[T](t: T) { | |
def foo: T = { | |
println("effect") | |
t | |
} | |
} |
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.language.higherKinds | |
class Cartesian[F[_]] { | |
trait Arbitrary1 | |
trait Arbitrary2 | |
implicit val fa1: F[Arbitrary1] = null.asInstanceOf | |
implicit val fa2: F[Arbitrary2] = null.asInstanceOf | |
class QED | |
implicit def proof(implicit fa12: F[(Arbitrary1, Arbitrary2)]): QED = null | |
} |
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
@annotation.inductive | |
trait Show[T] { | |
def show(t: T): String | |
} | |
object Show { | |
implicit def showUnit: Show[Unit] = new Show[Unit] { | |
def show(u: Unit): String = "()" | |
} |
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" standalone="yes"?> | |
<config xmlns="http://artifactory.jfrog.org/xsd/1.8.1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.jfrog.org/xsd/artifactory-v1_8_1.xsd"> | |
<offlineMode>false</offlineMode> | |
<helpLinksEnabled>true</helpLinksEnabled> | |
<fileUploadMaxSizeMb>100</fileUploadMaxSizeMb> | |
<dateFormat>dd-MM-yy HH:mm:ss z</dateFormat> | |
<addons> | |
<showAddonsInfo>true</showAddonsInfo> | |
<showAddonsInfoCookie>1480700455180</showAddonsInfoCookie> | |
</addons> |