diff --git a/vhdlpp/sequential_emit.cc b/vhdlpp/sequential_emit.cc index 389063744..2a417d2eb 100644 --- a/vhdlpp/sequential_emit.cc +++ b/vhdlpp/sequential_emit.cc @@ -82,7 +82,7 @@ void IfSequential::write_to_stream(std::ostream&fd) { fd << "if "; cond_->write_to_stream(fd); - fd << " then " << endl; + fd << " then" << endl; for (list::iterator cur = if_.begin() ; cur != if_.end() ; ++cur) diff --git a/vhdlpp/subprogram.cc b/vhdlpp/subprogram.cc index 9441591a2..3ddb47de8 100644 --- a/vhdlpp/subprogram.cc +++ b/vhdlpp/subprogram.cc @@ -82,7 +82,8 @@ void SubprogramBody::write_to_stream(ostream&fd) const } else { fd << "--empty body" << endl; } - fd << "end function;" << endl; + + fd << "end function " << header_->name() << ";" << endl; } SubprogramHeader::SubprogramHeader(perm_string nam, list*ports,