diff options
Diffstat (limited to 'src/compiler')
-rw-r--r-- | src/compiler/scala/tools/nsc/backend/icode/GenICode.scala | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/compiler/scala/tools/nsc/backend/icode/GenICode.scala b/src/compiler/scala/tools/nsc/backend/icode/GenICode.scala index e8e251c2fa..0bf4bfe83c 100644 --- a/src/compiler/scala/tools/nsc/backend/icode/GenICode.scala +++ b/src/compiler/scala/tools/nsc/backend/icode/GenICode.scala @@ -456,8 +456,10 @@ abstract class GenICode extends SubComponent { val oldcleanups = ctx1.cleanups for (op <- ctx1.cleanups) op match { case MonitorRelease(m) => + if (settings.debug.value) log("removing " + m + " from cleanups: " + ctx1.cleanups) ctx1.bb.emit(LOAD_LOCAL(m)) ctx1.bb.emit(MONITOR_EXIT()) + ctx1.exitSynchronized(m) case Finalizer(f) => if (settings.debug.value) log("removing " + f + " from cleanups: " + ctx1.cleanups) // we have to run this without the same finalizer in |