diff options
| author | Andrew Waterman | 2016-04-14 22:56:28 -0700 |
|---|---|---|
| committer | Andrew Waterman | 2016-04-14 22:58:59 -0700 |
| commit | 86f6aa352ee90d1c32b06ffc0fb4aa8a4ce3567c (patch) | |
| tree | 4f446adf95a91ffe1152298271b576318708db74 /src | |
| parent | 4d9e3007aedffd41fd397e70f151883a967fc3a7 (diff) | |
Don't eagerly evaluate assertion failure strings
Users should assume it's OK to make them expensive to evaluate.
Diffstat (limited to 'src')
| -rw-r--r-- | src/main/scala/Chisel/CoreUtil.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/scala/Chisel/CoreUtil.scala b/src/main/scala/Chisel/CoreUtil.scala index db3cf678..bad7799a 100644 --- a/src/main/scala/Chisel/CoreUtil.scala +++ b/src/main/scala/Chisel/CoreUtil.scala @@ -59,7 +59,7 @@ object assert { /** An elaboration-time assertion, otherwise the same as the above run-time * assertion. */ - def apply(cond: Boolean, message: String) { + def apply(cond: Boolean, message: => String) { Predef.assert(cond, message) } |
