Closed as not planned
Description
➜ scala git:(2.12.x) git log --oneline -n 1 | cat
38628d11fc Merge pull request #6077 from retronym/topic/unbreak-windows
Ivy cache for that version is empty
➜ scala git:(2.12.x) find ~/.ivy2 -path '*38628d1*'
➜ scala git:(2.12.x)
Fetch bootstrapped version from https://scala-ci.typesafe.com/artifactory/scala-integration/ (built by https://scala-ci.typesafe.com/view/scala-bench/job/bootstrap-benchmark/321/consoleFull)
➜ scala git:(2.12.x) sbt -Dstarr.version=2.12.4-bin-38628d1 update
➜ scala git:(2.12.x) find ~/.ivy2 -path '*38628d1*.jar'
/Users/luc/.ivy2/cache/org.scala-lang/scala-compiler/jars/scala-compiler-2.12.4-bin-38628d1.jar
/Users/luc/.ivy2/cache/org.scala-lang/scala-library/jars/scala-library-2.12.4-bin-38628d1.jar
/Users/luc/.ivy2/cache/org.scala-lang/scala-reflect/jars/scala-reflect-2.12.4-bin-38628d1.jar
Just to make sure that the inliner worked when compiling this version (getOrElse
was inlined into orNull
)
➜ scala git:(2.12.x) unzip /Users/luc/.ivy2/cache/org.scala-lang/scala-library/jars/scala-library-2.12.4-bin-38628d1.jar scala/Option.class -d sandbox
➜ scala git:(2.12.x) cfr-decompiler sandbox/scala/Option.class
...
public final <A1> A1 orNull(Predef..less.colon.less<Null., A1> ev) {
if (this.isEmpty()) {
return (A1)ev.apply((Object)null);
}
return (A1)this.get();
}
...
Local bootstrap
➜ scala git:(2.12.x) sbt -Dstarr.version=2.12.4-bin-38628d1
> setupBootstrapQuick "no-publish-repo" "2.12.4-bin-38628d1-local"
> version
[info] library/*:version
[info] 2.12.4-bin-38628d1-local
> show scalacOptions
[info] library/compile:scalacOptions
[info] List(-opt:l:inline, -opt-inline-from:scala/**, -sourcepath, /Users/luc/scala/scala/src/library)
> publishLocal
[info] published scala-library to /Users/luc/.ivy2/local/org.scala-lang/scala-library/2.12.4-bin-38628d1-local/jars/scala-library.jar
...
[info] published scala-reflect to /Users/luc/.ivy2/local/org.scala-lang/scala-reflect/2.12.4-bin-38628d1-local/jars/scala-reflect.jar
...
[info] published scala-compiler to /Users/luc/.ivy2/local/org.scala-lang/scala-compiler/2.12.4-bin-38628d1-local/jars/scala-compiler.jar
Check if the inliner worked
➜ scala git:(2.12.x) rm -rf sandbox/scala
➜ scala git:(2.12.x) unzip /Users/luc/.ivy2/local/org.scala-lang/scala-library/2.12.4-bin-38628d1-local/jars/scala-library.jar scala/Option.class -d sandbox
➜ scala git:(2.12.x) cfr-decompiler sandbox/scala/Option.class
public final <A1> A1 orNull(Predef..less.colon.less<Null., A1> ev) {
if (this.isEmpty()) {
return (A1)ev.apply((Object)null);
}
return (A1)this.get();
}
Jardiff library
➜ scala git:(2.12.x) find ~/.ivy2 -path '*38628d1*.jar'
/Users/luc/.ivy2/cache/org.scala-lang/scala-library/jars/scala-library-2.12.4-bin-38628d1.jar
...
/Users/luc/.ivy2/local/org.scala-lang/scala-library/2.12.4-bin-38628d1-local/jars/scala-library.jar
➜ scala git:(2.12.x) jardiff /Users/luc/.ivy2/cache/org.scala-lang/scala-library/jars/scala-library-2.12.4-bin-38628d1.jar /Users/luc/.ivy2/local/org.scala-lang/scala-library/2.12.4-bin-38628d1-local/jars/scala-library.jar
https://gist.github.com/lrytz/2d582b3cc03f4d8bfed9800658c35844