Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
D
doxverilog
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
doxverilog
Commits
b4fd6ac5
Commit
b4fd6ac5
authored
Dec 22, 2014
by
Dimitri van Heesch
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bug 739210 - C++11 scoped enums with same name inside different classes are merged if using tagfile
parent
cba0d89f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
12 deletions
+16
-12
doxygen.cpp
src/doxygen.cpp
+16
-12
No files found.
src/doxygen.cpp
View file @
b4fd6ac5
...
@@ -7038,7 +7038,7 @@ static void findEnums(EntryNav *rootNav)
...
@@ -7038,7 +7038,7 @@ static void findEnums(EntryNav *rootNav)
if
(
cd
&&
!
name
.
isEmpty
())
// found a enum inside a compound
if
(
cd
&&
!
name
.
isEmpty
())
// found a enum inside a compound
{
{
//printf("Enum `%s'::`%s'\n",cd->name(),name.data());
//printf("Enum `%s'::`%s'\n",cd->name()
.data()
,name.data());
fd
=
0
;
fd
=
0
;
mnsd
=
Doxygen
::
memberNameSDict
;
mnsd
=
Doxygen
::
memberNameSDict
;
isGlobal
=
FALSE
;
isGlobal
=
FALSE
;
...
@@ -7071,17 +7071,17 @@ static void findEnums(EntryNav *rootNav)
...
@@ -7071,17 +7071,17 @@ static void findEnums(EntryNav *rootNav)
if
(
!
isGlobal
)
md
->
setMemberClass
(
cd
);
else
md
->
setFileDef
(
fd
);
if
(
!
isGlobal
)
md
->
setMemberClass
(
cd
);
else
md
->
setFileDef
(
fd
);
md
->
setBodySegment
(
root
->
bodyLine
,
root
->
endBodyLine
);
md
->
setBodySegment
(
root
->
bodyLine
,
root
->
endBodyLine
);
md
->
setBodyDef
(
rootNav
->
fileDef
());
md
->
setBodyDef
(
rootNav
->
fileDef
());
md
->
setMemberSpecifiers
(
root
->
spec
);
// UNO IDL "published"
md
->
setMemberSpecifiers
(
root
->
spec
);
md
->
setEnumBaseType
(
root
->
args
);
md
->
setEnumBaseType
(
root
->
args
);
//printf("Enum %s definition at line %d of %s: protection=%d\n",
//printf("Enum %s definition at line %d of %s: protection=%d
scope=%s
\n",
// root->name.data(),root->bodyLine,root->fileName.data(),root->protection);
// root->name.data(),root->bodyLine,root->fileName.data(),root->protection
,cd?cd->name().data():"<none>"
);
md
->
addSectionsToDefinition
(
root
->
anchors
);
md
->
addSectionsToDefinition
(
root
->
anchors
);
md
->
setMemberGroupId
(
root
->
mGrpId
);
md
->
setMemberGroupId
(
root
->
mGrpId
);
md
->
enableCallGraph
(
root
->
callGraph
);
md
->
enableCallGraph
(
root
->
callGraph
);
md
->
enableCallerGraph
(
root
->
callerGraph
);
md
->
enableCallerGraph
(
root
->
callerGraph
);
//printf("%s::setRefItems(%d)\n",md->name().data(),root->sli?root->sli->count():-1);
//printf("%s::setRefItems(%d)\n",md->name().data(),root->sli?root->sli->count():-1);
md
->
setRefItems
(
root
->
sli
);
md
->
setRefItems
(
root
->
sli
);
//printf("found enum %s nd=%p\n",
name
.data(),nd);
//printf("found enum %s nd=%p\n",
md->name()
.data(),nd);
bool
defSet
=
FALSE
;
bool
defSet
=
FALSE
;
QCString
baseType
=
root
->
args
;
QCString
baseType
=
root
->
args
;
...
@@ -7255,23 +7255,27 @@ static void addEnumValuesToEnums(EntryNav *rootNav)
...
@@ -7255,23 +7255,27 @@ static void addEnumValuesToEnums(EntryNav *rootNav)
{
{
SrcLangExt
sle
;
SrcLangExt
sle
;
if
(
if
(
(
sle
=
rootNav
->
lang
())
==
SrcLangExt_CSharp
||
(
sle
=
rootNav
->
lang
())
==
SrcLangExt_CSharp
||
sle
==
SrcLangExt_Java
||
sle
==
SrcLangExt_Java
||
sle
==
SrcLangExt_XML
||
sle
==
SrcLangExt_XML
||
(
root
->
spec
&
Entry
::
Strong
)
(
root
->
spec
&
Entry
::
Strong
)
)
)
{
{
// Unlike classic C/C++ enums, for C++11, C# & Java enum
// Unlike classic C/C++ enums, for C++11, C# & Java enum
// values are only visible inside the enum scope, so we must create
// values are only visible inside the enum scope, so we must create
// them here and only add them to the enum
// them here and only add them to the enum
e
->
loadEntry
(
g_storage
);
e
->
loadEntry
(
g_storage
);
Entry
*
root
=
e
->
entry
();
Entry
*
root
=
e
->
entry
();
//printf("md->qualifiedName()=%s rootNav->name()=%s tagInfo=%p name=%s\n",
//printf("md->qualifiedName()=%s rootNav->name()=%s tagInfo=%p name=%s\n",
// md->qualifiedName().data(),rootNav->name().data(),rootNav->tagInfo(),root->name.data());
// md->qualifiedName().data(),rootNav->name().data(),rootNav->tagInfo(),root->name.data());
QCString
qualifiedName
=
substitute
(
rootNav
->
name
(),
"::"
,
"."
);
if
(
!
scope
.
isEmpty
()
&&
rootNav
->
tagInfo
())
{
qualifiedName
=
substitute
(
scope
,
"::"
,
"."
)
+
"."
+
qualifiedName
;
}
if
(
substitute
(
md
->
qualifiedName
(),
"::"
,
"."
)
==
// TODO: add function to get canonical representation
if
(
substitute
(
md
->
qualifiedName
(),
"::"
,
"."
)
==
// TODO: add function to get canonical representation
substitute
(
rootNav
->
name
(),
"::"
,
"."
)
||
// enum value scope matches that of the enum
qualifiedName
// enum value scope matches that of the enum
rootNav
->
tagInfo
()
// be less strict for tag files as members can have incomplete scope
)
)
{
{
MemberDef
*
fmd
=
new
MemberDef
(
MemberDef
*
fmd
=
new
MemberDef
(
root
->
fileName
,
root
->
startLine
,
root
->
startColumn
,
root
->
fileName
,
root
->
startLine
,
root
->
startColumn
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment