From 77dae25c166c71a57d9ecd64b765bcc616d435ec Mon Sep 17 00:00:00 2001 From: Christopher Friedt Date: Wed, 8 May 2019 21:46:48 -0400 Subject: make similar javadoc banner change for stripping special comments from code --- src/code.l | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/src/code.l b/src/code.l index 8c6e23b..1f3bd3e 100644 --- a/src/code.l +++ b/src/code.l @@ -3553,6 +3553,24 @@ RAWEND ")"[^ \t\(\)\\]{0,16}\" BEGIN(SkipComment); } } +<*>^{B}*"/**"[*]+/[^/] { // special C "banner" comment block at a new line + if (Config_getBool(JAVADOC_BANNER) && Config_getBool(STRIP_CODE_COMMENTS)) + { + g_lastSpecialCContext = YY_START; + BEGIN(RemoveSpecialCComment); + } + else + { + // check is to prevent getting stuck in skipping C++ comments + if (YY_START != SkipCxxComment) + { + g_lastCContext = YY_START ; + } + startFontClass("comment"); + g_code->codify(yytext); + BEGIN(SkipComment); + } + } <*>^{B}*"/*"[!*]/[^/*] { // special C comment block at a new line if (Config_getBool(STRIP_CODE_COMMENTS)) { -- cgit v0.12