On 2023-06-14 00:19:58 +0200, Vincent Lefevre wrote:
> When a comment block is used, i.e.
> 
> =begin comment
> 
> [code to comment]
> 
> =end comment
> 
> =cut
> 
> as described in the perlfaq7 man page, everything starting at the
> "=begin comment" line is in the comment color, even the code after
> the "=cut" line (which is no longer commented code).

Well, just after loading a file, coloring seem correct. But after
edition, it can quickly become incorrect.

To reproduce the bug:

1. Create a file with

----------------------------------------
#!/usr/bin/env perl

foo;

=begin comment

bar;

=end comment

=cut

print "OK\n";
----------------------------------------

2. Open it with "emacs -Q".
3. M-x cperl-mode
4. Go to the beginning of line "foo;".
5. C-k
6. Go to the beginning of line "bar;".
7. C-y

At step 7, the color of the line

  print "OK\n";

changes to the comment color.

This occurs whether the Emacs X11 interface is used or not.

-- 
Vincent Lefèvre <vinc...@vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)

Reply via email to