summaryrefslogtreecommitdiffstats
path: root/src/util.cpp
diff options
context:
space:
mode:
authordimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7>2003-11-21 13:10:40 (GMT)
committerdimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7>2003-11-21 13:10:40 (GMT)
commit4d3dea2f08f3bed73db5c3b8dc3772e46decb479 (patch)
treeb21e4aeb8cabee272c641732f0e77e90433030e3 /src/util.cpp
parent8a5c51f2c968dee1283dce092e1ccc0d3df91f0e (diff)
downloadDoxygen-4d3dea2f08f3bed73db5c3b8dc3772e46decb479.zip
Doxygen-4d3dea2f08f3bed73db5c3b8dc3772e46decb479.tar.gz
Doxygen-4d3dea2f08f3bed73db5c3b8dc3772e46decb479.tar.bz2
Release-1.3.5
Diffstat (limited to 'src/util.cpp')
-rw-r--r--src/util.cpp37
1 files changed, 23 insertions, 14 deletions
diff --git a/src/util.cpp b/src/util.cpp
index 4a0e1ab..d268f8e 100644
--- a/src/util.cpp
+++ b/src/util.cpp
@@ -565,6 +565,7 @@ int isAccessibleFrom(Definition *scope,FileDef *fileScope,Definition *item,
*/
ClassDef *newResolveTypedef(FileDef *fileScope,MemberDef *md,QCString *pTemplSpec)
{
+ //printf("newResolveTypedef(md=%p,cachedVal=%p)\n",md,md->getCachedTypedefVal());
bool isCached = md->isTypedefValCached(); // value already cached
if (isCached)
{
@@ -606,7 +607,14 @@ ClassDef *newResolveTypedef(FileDef *fileScope,MemberDef *md,QCString *pTemplSpe
}
// remember computed value for next time
- md->cacheTypedefVal(result);
+ if (result && result->getDefFileName()!="<code>")
+ // this check is needed to prevent that temporary classes that are
+ // introduced while parsing code fragments are being cached here.
+ {
+ //printf("setting cached typedef %p in result %p\n",md,result);
+ //printf("==> %s (%s,%d)\n",result->name().data(),result->getDefFileName().data(),result->getDefLine());
+ md->cacheTypedefVal(result);
+ }
g_resolvedTypedefs.remove(qname); // remove from the trace list
@@ -3542,10 +3550,10 @@ QCString stripScope(const char *name)
}
/*! Convert nibble (range 0..15) to hex char */
-static char nibbleToHex(int n)
-{
- return (n < 10) ? ('0'+n) : ('a'+n-10);
-}
+//static char nibbleToHex(int n)
+//{
+// return (n < 10) ? ('0'+n) : ('a'+n-10);
+//}
/*! Converts a string to an XML-encoded string */
QCString convertToXML(const char *s)
@@ -3564,16 +3572,17 @@ QCString convertToXML(const char *s)
case '\'': result+="&apos;"; break;
case '"': result+="&quot;"; break;
default:
- if (c<0)
- {
- result+=(QCString)"&#x" +
- nibbleToHex((((uchar)c)>>4)&0xf)+
- nibbleToHex(c&0xf)+";";
- }
- else
- {
+ //if (c<0)
+ //{ <- this doesn't work for languages that use
+ // characters with codes beyond 255
+ // result+=(QCString)"&#x" +
+ // nibbleToHex((((uchar)c)>>4)&0xf)+
+ // nibbleToHex(c&0xf)+";";
+ //}
+ //else
+ //{
result+=c;
- }
+ //}
break;
}
}