summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDimitri van Heesch <dimitri@stack.nl>2013-09-13 13:38:59 (GMT)
committerDimitri van Heesch <dimitri@stack.nl>2013-09-13 13:38:59 (GMT)
commit0de73f595c8695344860cfc65d1d260b1e3c8c15 (patch)
treeed1efd6332aca5f9ccfde475c87ec5d4dfeaf355
parentb07832a11606e3d1b488ee2ab4ec34bb6ccb7921 (diff)
parent40153a83f9bddb54add6a7247cf22fbc8e36dc10 (diff)
downloadDoxygen-0de73f595c8695344860cfc65d1d260b1e3c8c15.zip
Doxygen-0de73f595c8695344860cfc65d1d260b1e3c8c15.tar.gz
Doxygen-0de73f595c8695344860cfc65d1d260b1e3c8c15.tar.bz2
Merge branch 'for-upstream' of https://github.com/groleo/doxygen-1 into groleo-for-upstream
-rw-r--r--src/util.cpp15
1 files changed, 14 insertions, 1 deletions
diff --git a/src/util.cpp b/src/util.cpp
index e67e9fb..83eb095 100644
--- a/src/util.cpp
+++ b/src/util.cpp
@@ -4307,7 +4307,20 @@ bool getDefs(const QCString &scName,
//printf("found %d candidate members\n",members.count());
if (members.count()>0) // at least one match
{
- md=members.last();
+ if (currentFile)
+ {
+ //printf("multiple results; pick one from file:%s\n", currentFile->name().data());
+ md = members.first();
+ while (md) {
+ if (md->getFileDef()->name() == currentFile->name())
+ break;
+ md=members.next();
+ }
+ if (!md)
+ md=members.last();
+ } else {
+ md=members.last();
+ }
}
if (md && (md->getEnumScope()==0 || !md->getEnumScope()->isStrong()))
// found a matching global member, that is not a scoped enum value (or uniquely matches)