summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/scripts/latexindent/LatexIndent/TrailingComments.pm
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/scripts/latexindent/LatexIndent/TrailingComments.pm')
-rw-r--r--Master/texmf-dist/scripts/latexindent/LatexIndent/TrailingComments.pm10
1 files changed, 5 insertions, 5 deletions
diff --git a/Master/texmf-dist/scripts/latexindent/LatexIndent/TrailingComments.pm b/Master/texmf-dist/scripts/latexindent/LatexIndent/TrailingComments.pm
index bbae745d940..748d005f98e 100644
--- a/Master/texmf-dist/scripts/latexindent/LatexIndent/TrailingComments.pm
+++ b/Master/texmf-dist/scripts/latexindent/LatexIndent/TrailingComments.pm
@@ -67,16 +67,16 @@ sub remove_trailing_comments {
$logger->trace("*Storing trailing comments") if $is_t_switch_active;
my $notPreceededBy = qr/${${$mainSettings{fineTuning}}{trailingComments}}{notPreceededBy}/;
+ my $afterComment = qr/${${$mainSettings{fineTuning}}{trailingComments}}{afterComment}/;
# perform the substitution
${$self}{body} =~ s/
- $notPreceededBy # not preceded by a \
- % # %
+ $notPreceededBy # not preceded by a \
+ % # %
(
- \h*? # followed by possible horizontal space
- .*? # and anything else
+ $afterComment # anything else
)
- $ # up to the end of a line
+ $ # up to the end of a line
/
# increment comment counter and store comment
$commentCounter++;