From 5b2d94a274abe82d26687f1c6ef19fb1d57df2dd Mon Sep 17 00:00:00 2001 From: Martin Odersky Date: Sat, 31 Oct 2015 09:57:50 +0100 Subject: Check that access to context base is singlethreaded. ContextBase is not intended to be threadsafe, We now test that indeed it is not shared by compileUnits calls operating on different threads. --- src/dotty/tools/dotc/Run.scala | 1 + 1 file changed, 1 insertion(+) (limited to 'src/dotty/tools/dotc/Run.scala') diff --git a/src/dotty/tools/dotc/Run.scala b/src/dotty/tools/dotc/Run.scala index 114f994be..ba86e3e70 100644 --- a/src/dotty/tools/dotc/Run.scala +++ b/src/dotty/tools/dotc/Run.scala @@ -50,6 +50,7 @@ class Run(comp: Compiler)(implicit ctx: Context) { } protected def compileUnits() = Stats.monitorHeartBeat { + ctx.checkSingleThreaded() val phases = ctx.squashPhases(ctx.phasePlan, ctx.settings.Yskip.value, ctx.settings.YstopBefore.value, ctx.settings.YstopAfter.value, ctx.settings.Ycheck.value) ctx.usePhases(phases) -- cgit v1.2.3