Skip to content

Run CI-partest with bootstrapped compiler #853

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Oct 23, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions project/Build.scala
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ object DottyBuild extends Build {
val args = Def.spaceDelimited("<arg>").parsed
val jars = Seq((packageBin in Compile).value.getAbsolutePath) ++
getJarPaths(partestDeps.value, ivyPaths.value.ivyHome)
val dottyJars = "-dottyJars " + jars.length + " " + jars.mkString(" ")
val dottyJars = "-dottyJars " + (jars.length + 1) + " dotty.jar" + " " + jars.mkString(" ")
// Provide the jars required on the classpath of run tests
runTask(Test, "dotty.partest.DPConsoleRunner", dottyJars + " " + args.mkString(" "))
},
Expand Down Expand Up @@ -118,8 +118,8 @@ object DottyBuild extends Build {

("-DpartestParentID=" + pid) :: tuning ::: agentOptions ::: travis_build ::: fullpath
}
) ++ addCommandAlias("partest", ";test:package;package;lockPartestFile;test:test;runPartestRunner") ++
addCommandAlias("partest-only", ";test:package;package;lockPartestFile;test:test-only dotc.tests;runPartestRunner")
) ++ addCommandAlias("partest", ";test:package;package;test:runMain dotc.build;lockPartestFile;test:test;runPartestRunner") ++
addCommandAlias("partest-only", ";test:package;package;test:runMain dotc.build;lockPartestFile;test:test-only dotc.tests;runPartestRunner")

lazy val dotty = Project(id = "dotty", base = file("."), settings = defaults)

Expand Down
2 changes: 1 addition & 1 deletion scripts/jobs/validate/partest
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ baseDir=${WORKSPACE-`pwd`}
scriptsDir="$baseDir/scripts"
. $scriptsDir/common

sbt $sbtArgs update compile "partest-only run --show-diff --verbose"
sbt $sbtArgs update compile "partest-only --show-diff --verbose"

10 changes: 7 additions & 3 deletions src/dotty/tools/dotc/core/Denotations.scala
Original file line number Diff line number Diff line change
Expand Up @@ -193,9 +193,11 @@ object Denotations {
*/
def requiredSymbol(p: Symbol => Boolean, source: AbstractFile = null, generateStubs: Boolean = true)(implicit ctx: Context): Symbol =
disambiguate(p) match {
case MissingRef(ownerd, name) =>
if (generateStubs)
case m @ MissingRef(ownerd, name) =>
if (generateStubs) {
m.ex.printStackTrace()
ctx.newStubSymbol(ownerd.symbol, name, source)
}
else NoSymbol
case NoDenotation | _: NoQualifyingRef =>
throw new TypeError(s"None of the alternatives of $this satisfies required predicate")
Expand Down Expand Up @@ -858,7 +860,9 @@ object Denotations {
/** An error denotation that provides more info about the missing reference.
* Produced by staticRef, consumed by requiredSymbol.
*/
case class MissingRef(val owner: SingleDenotation, name: Name)(implicit ctx: Context) extends ErrorDenotation
case class MissingRef(val owner: SingleDenotation, name: Name)(implicit ctx: Context) extends ErrorDenotation {
val ex: Exception = new Exception
}

/** An error denotation that provides more info about alternatives
* that were found but that do not qualify.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -405,6 +405,7 @@ class Scala2Unpickler(bytes: Array[Byte], classRoot: ClassDenotation, moduleClas
// println(owner.info.decls.toList.map(_.debugString).mkString("\n ")) // !!! DEBUG
// }
// (5) Create a stub symbol to defer hard failure a little longer.
new Exception().printStackTrace()
ctx.newStubSymbol(owner, name, source)
}
}
Expand Down