vhdlpp: Add 'sub' prefix for subtypes while emitting packages.

This commit is contained in:
Maciej Suminski 2015-04-24 17:01:11 +02:00
parent a33bbecc98
commit ddc204391e
1 changed files with 6 additions and 0 deletions

View File

@ -74,6 +74,9 @@ void Package::write_to_stream(ostream&fd) const
if (is_global_type(cur->first))
continue;
if(!dynamic_cast<const VTypeDef*>(cur->second))
fd << "sub";
fd << "type " << cur->first << " is ";
cur->second->write_type_to_stream(fd);
fd << "; -- imported" << endl;
@ -85,6 +88,9 @@ void Package::write_to_stream(ostream&fd) const
if (is_global_type(cur->first))
continue;
if(!dynamic_cast<const VTypeDef*>(cur->second))
fd << "sub";
fd << "type " << cur->first << " is ";
cur->second->write_type_to_stream(fd);
fd << ";" << endl;