Skip to content
Browse files

an amazing discovery made by Iulian

Traces were stalling macro expansions by evaluating messages even when
-Ymacro-debug-* flags were disabled.
  • Loading branch information...
1 parent b7b4f87 commit 5db04eb0ddf53f183a5b61616d037f6b558eba5c @xeno-by xeno-by committed Mar 18, 2013
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/compiler/scala/tools/nsc/util/SimpleTracer.scala
View
2 src/compiler/scala/tools/nsc/util/SimpleTracer.scala
@@ -10,7 +10,7 @@ import java.io.PrintStream
* @param enabled: A condition that must be true for trace info to be produced.
*/
class SimpleTracer(out: PrintStream, enabled: Boolean = true) {
- def apply[T](msg: String)(value: T): T = {
+ def apply[T](msg: => String)(value: T): T = {
if (enabled) out.println(msg+value)
value
}

2 comments on commit 5db04eb

@scala-jenkins

Job pr-rangepos-per-commit failed for 5db04eb (results):


Took 6 s.
to rebuild, comment "PLS REBUILD/pr-rangepos-per-commit@5db04eb" on PR 2276

@scala-jenkins

Job pr-checkin-per-commit failed for 5db04eb (results):


Took 42 s.
to rebuild, comment "PLS REBUILD/pr-checkin-per-commit@5db04eb" on PR 2276

Please sign in to comment.
Something went wrong with that request. Please try again.