summaryrefslogtreecommitdiff
path: root/src/main/scala/Chisel/testers/BasicTester.scala
diff options
context:
space:
mode:
authorducky2016-05-05 13:22:04 -0700
committerducky2016-05-20 16:02:49 -0700
commite92f2f69477a6ce86fc148a1a95db5797f2e3051 (patch)
tree2f1511e3395299fd4f1e98c3f75886e06c0cd096 /src/main/scala/Chisel/testers/BasicTester.scala
parent84de04606bc972bd6a83f67913a0e30c4c46ee5e (diff)
Implementation of source locators
Diffstat (limited to 'src/main/scala/Chisel/testers/BasicTester.scala')
-rw-r--r--src/main/scala/Chisel/testers/BasicTester.scala8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/main/scala/Chisel/testers/BasicTester.scala b/src/main/scala/Chisel/testers/BasicTester.scala
index d3e9e7c8..b8c1494a 100644
--- a/src/main/scala/Chisel/testers/BasicTester.scala
+++ b/src/main/scala/Chisel/testers/BasicTester.scala
@@ -3,9 +3,12 @@
package Chisel.testers
import Chisel._
+import scala.language.experimental.macros
+
import internal._
import internal.Builder.pushCommand
import internal.firrtl._
+import internal.sourceinfo.SourceInfo
class BasicTester extends Module {
// The testbench has no IOs, rather it should communicate using printf, assert, and stop.
@@ -19,9 +22,10 @@ class BasicTester extends Module {
* reset). If your definition of reset is not the encapsulating Module's
* reset, you will need to gate this externally.
*/
- def stop() {
+ def stop()(implicit sourceInfo: SourceInfo) {
+ // TODO: rewrite this using library-style SourceInfo passing.
when (!reset) {
- pushCommand(Stop(Node(clock), 0))
+ pushCommand(Stop(sourceInfo, Node(clock), 0))
}
}