summaryrefslogtreecommitdiff
path: root/chiselFrontend/src/main/scala/chisel3/core
diff options
context:
space:
mode:
authorJim Lawson2016-11-10 10:05:15 -0800
committerJim Lawson2016-11-10 10:05:15 -0800
commit2e62da09ed1ed0725a14185ae76a683da73b32f4 (patch)
tree29cc5966074ba9eb71c4a8bced5d8ff1f2601cae /chiselFrontend/src/main/scala/chisel3/core
parentb2b80ce24881782b82b545e0e3cb2a0e4ef83557 (diff)
Throw exceptions for cloneType failures - fix #358
Add a Builder.exception() method for those cases where continuing is likely to mask the initial error.
Diffstat (limited to 'chiselFrontend/src/main/scala/chisel3/core')
-rw-r--r--chiselFrontend/src/main/scala/chisel3/core/Aggregate.scala4
1 files changed, 2 insertions, 2 deletions
diff --git a/chiselFrontend/src/main/scala/chisel3/core/Aggregate.scala b/chiselFrontend/src/main/scala/chisel3/core/Aggregate.scala
index de7af462..68fe0bb5 100644
--- a/chiselFrontend/src/main/scala/chisel3/core/Aggregate.scala
+++ b/chiselFrontend/src/main/scala/chisel3/core/Aggregate.scala
@@ -408,12 +408,12 @@ class Bundle extends Aggregate {
constructor.newInstance(_parent.get).asInstanceOf[this.type]
} catch {
case _: java.lang.reflect.InvocationTargetException | _: java.lang.IllegalArgumentException =>
- Builder.error(s"Parameterized Bundle ${this.getClass} needs cloneType method. You are probably using " +
+ Builder.exception(s"Parameterized Bundle ${this.getClass} needs cloneType method. You are probably using " +
"an anonymous Bundle object that captures external state and hence is un-cloneTypeable")
this
}
case _: java.lang.reflect.InvocationTargetException | _: java.lang.IllegalArgumentException =>
- Builder.error(s"Parameterized Bundle ${this.getClass} needs cloneType method")
+ Builder.exception(s"Parameterized Bundle ${this.getClass} needs cloneType method")
this
}
}