summaryrefslogtreecommitdiffstats
path: root/src/pre.l
diff options
context:
space:
mode:
Diffstat (limited to 'src/pre.l')
-rw-r--r--src/pre.l17
1 files changed, 12 insertions, 5 deletions
diff --git a/src/pre.l b/src/pre.l
index 7c85873..667f272 100644
--- a/src/pre.l
+++ b/src/pre.l
@@ -560,7 +560,11 @@ static bool replaceFunctionMacro(const QCString &expr,QCString *rest,int pos,int
}
else
{
- if (g_nospaces)
+ if (hash && substArg.isEmpty())
+ {
+ resExpr+="@E"; // empty argument will be remove later on
+ }
+ else if (g_nospaces)
{
resExpr+=substArg;
}
@@ -715,10 +719,9 @@ static void expandExpression(QCString &expr,QCString *rest,int pos)
}
}
-/*! replaces all occurrences of @@ in \a s by @
+/*! replaces all occurrences of @@@@ in \a s by @@
+ * and removes all occurrences of @@E.
* All identifiers found are replaced by 0L
- * \par assumption:
- * \a s only contains pairs of @@'s.
*/
QCString removeIdsAndMarkers(const char *s)
{
@@ -731,12 +734,16 @@ QCString removeIdsAndMarkers(const char *s)
{
while ((c=*p))
{
- if (c=='@') // replace @@ with @
+ if (c=='@') // replace @@ with @ and remove @E
{
if (*(p+1)=='@')
{
result+=c;
}
+ else if (*(p+1)=='E')
+ {
+ // skip
+ }
p+=2;
}
else if (isdigit(c)) // number