diff options
author | Dimitri van Heesch <dimitri@stack.nl> | 2010-11-18 21:50:39 (GMT) |
---|---|---|
committer | Dimitri van Heesch <dimitri@stack.nl> | 2010-11-18 21:50:39 (GMT) |
commit | dd7602fdd31d8f3e0f88be553da084a1e3fdec45 (patch) | |
tree | a6d2454b4e6d53003fa829bb7134fe373461ed97 /src/code.l | |
parent | be602ee76006d9b8b0f6e5e75114f2ce34f7773e (diff) | |
download | Doxygen-dd7602fdd31d8f3e0f88be553da084a1e3fdec45.zip Doxygen-dd7602fdd31d8f3e0f88be553da084a1e3fdec45.tar.gz Doxygen-dd7602fdd31d8f3e0f88be553da084a1e3fdec45.tar.bz2 |
Release-1.7.2-20101118
Diffstat (limited to 'src/code.l')
-rw-r--r-- | src/code.l | 10 |
1 files changed, 6 insertions, 4 deletions
@@ -621,7 +621,7 @@ static void addParmType() static void addUsingDirective(const char *name) { - if (g_exampleBlock && g_sourceFileDef && name) + if (g_sourceFileDef && name) { NamespaceDef *nd = Doxygen::namespaceSDict->find(name); if (nd) @@ -3394,10 +3394,12 @@ void parseCCode(CodeOutputInterface &od,const char *className,const QCString &s, g_exampleName = exName; g_sourceFileDef = fd; g_lineNumbers = fd!=0 && showLineNumbers; - if (exBlock && fd==0) + bool cleanupSourceDef = FALSE; + if (/* exBlock */ fd==0) { // create a dummy filedef for the example - g_sourceFileDef = new FileDef("",exName); + g_sourceFileDef = new FileDef("",(exName?exName:"generated")); + cleanupSourceDef = TRUE; } if (g_sourceFileDef) { @@ -3433,7 +3435,7 @@ void parseCCode(CodeOutputInterface &od,const char *className,const QCString &s, endFontClass(); g_code->endCodeLine(); } - if (exBlock && fd==0) + if (cleanupSourceDef) { // delete the temporary file definition used for this example delete g_sourceFileDef; |