From 3e551ef38fb4c01b9b46f45dc68c2d9f5c9e9acb Mon Sep 17 00:00:00 2001 From: mergify[bot] Date: Mon, 25 Apr 2022 23:19:37 +0000 Subject: Fix error message for BlackBox without val io <: Record (#2504) (#2505) (cherry picked from commit f9aee1f72744abc6ee13aafc4d1a51a2783cbab8) Co-authored-by: Jack Koenig --- core/src/main/scala/chisel3/BlackBox.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'core') diff --git a/core/src/main/scala/chisel3/BlackBox.scala b/core/src/main/scala/chisel3/BlackBox.scala index 2f04fb2e..f3fc2711 100644 --- a/core/src/main/scala/chisel3/BlackBox.scala +++ b/core/src/main/scala/chisel3/BlackBox.scala @@ -157,7 +157,7 @@ abstract class BlackBox( _compatAutoWrapPorts() // pre-IO(...) compatibility hack // Restrict IO to just io, clock, and reset - if (!_io.forall(portsContains)) { + if (!_io.exists(portsContains)) { throwException(s"BlackBox '$this' must have a port named 'io' of type Record wrapped in IO(...)!") } -- cgit v1.2.3