From 8451615142377edb4ead75a705c39b1ece22d833 Mon Sep 17 00:00:00 2001 From: acli Date: Wed, 25 Feb 2004 06:56:42 +0000 Subject: [PATCH] Ugly hack to avoid screenfuls of spurious warnings about "Possible SGML closed tag notation" --- misc/translator/TmplTokenizer.pm | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/misc/translator/TmplTokenizer.pm b/misc/translator/TmplTokenizer.pm index 46acb1c0fb..23eb8aab11 100644 --- a/misc/translator/TmplTokenizer.pm +++ b/misc/translator/TmplTokenizer.pm @@ -361,8 +361,14 @@ sub _next_token_internal { my($head, $tail, $post) = ($1, $2, $3); if ($tail eq '' && $post =~ $re_tmpl_var) { # Don't bother to show the warning if we're too confused + # FIXME. There's no method for _closed_start_tag_warning + if (!defined $this->{'_closed_start_tag_warning'} + || ($this->{'_closed_start_tag_warning'}->[0] eq $head + && $this->{'_closed_start_tag_warning'}->[1] != $this->line_number - 1)) { warn_normal "Possible SGML \"closed start tag\" notation: $head<\n", $this->line_number if split(/\n/, $head) < 10; + } + $this->{'_closed_start_tag_warning'} = [$head, $this->line_number]; } else { ($kind, $it) = (TmplTokenType::TAG, "$head>"); $this->_set_readahead( $post ); -- 2.39.5