diff --git a/PWire.cc b/PWire.cc index bf9b36954..5cba7ef97 100644 --- a/PWire.cc +++ b/PWire.cc @@ -98,12 +98,10 @@ bool PWire::set_port_type(NetNet::PortType pt) switch (port_type_) { case NetNet::PIMPLICIT: + case NetNet::NOT_A_PORT: port_type_ = pt; return true; - case NetNet::NOT_A_PORT: - return false; - default: if (port_type_ != pt) return false; diff --git a/pform.cc b/pform.cc index 374040291..8c211b1ef 100644 --- a/pform.cc +++ b/pform.cc @@ -3413,18 +3413,12 @@ static void pform_set_port_type(const struct vlltype&li, } switch (cur->get_port_type()) { + case NetNet::NOT_A_PORT: case NetNet::PIMPLICIT: if (! cur->set_port_type(pt)) VLerror("error setting port direction."); break; - case NetNet::NOT_A_PORT: - cerr << li << ": error: " - << "port " << name << " is not in the port list." - << endl; - error_count += 1; - break; - default: cerr << li << ": error: " << "port " << name << " already has a port declaration."