Skip to content

Commit 3372fcc

Browse files
committed
issue #9964 [VHDL] - type and name of type in type-generic entity are swapped
With update: ``` Commit: 4b155ef [4b155ef] Date: Saturday, May 20, 2023 11:21:29 AM parser update to vhdl2017 ``` the part ``` else if(m_sharedState->generic_sec){ outlineParser()->addVhdlType(s.data(),outlineParser()->getLine(),Entry::VARIABLE_SEC,VhdlDocGen::GENERIC,s1.data(),s1.data(),Protection::Public); } ``` was, accidently, removed. Reintroduced it and corrected the type line as indicated in #9964 (comment) also the `generic_sec` was not present anymore, test thtough `parse_sec`.
1 parent cf818b6 commit 3372fcc

File tree

3 files changed

+2301
-2295
lines changed

3 files changed

+2301
-2295
lines changed

vhdlparser/VhdlParser.cc

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7296,14 +7296,17 @@ QCString VhdlParser::interface_incomplete_type_declaration() {QCString s="type";
72967296
s1 = identifier();
72977297
}
72987298
if (m_sharedState->currP!=VhdlDocGen::COMPONENT && m_sharedState->interf_sec==false)
7299+
{
7300+
if (m_sharedState->currP==VhdlDocGen::FUNCTION || m_sharedState->currP==VhdlDocGen::PROCEDURE)
72997301
{
7300-
if (m_sharedState->currP==VhdlDocGen::FUNCTION || m_sharedState->currP==VhdlDocGen::PROCEDURE)
7301-
{
7302-
outlineParser()->addProto("",s1.data(),s.data(),"","","");
7303-
}
7304-
7302+
outlineParser()->addProto("",s1.data(),s.data(),"","","");
7303+
}
7304+
else if(m_sharedState->parse_sec==GEN_SEC)
7305+
{
7306+
outlineParser()->addVhdlType(s.data(),outlineParser()->getLine(),Entry::VARIABLE_SEC,VhdlDocGen::GENERIC,s1.data(),"",Protection::Public);
7307+
}
73057308

7306-
return s+" "+s1;
7309+
return s+" "+s1;
73077310
}
73087311
assert(false);
73097312
}

0 commit comments

Comments
 (0)