Sublime Forum

PHP Comment Syntax Highlighting

#1

The new version of Sublime (4143) suddenly has a wrong highlight of a multiline comment block in PHP when PHP’s closing tag is inside the multiline comment block. This is not an error in PHP, and before this version, everyting inside of a multiline comment block was higlighted as a comment.

Code example:

<?php /*if (! empty($var)) { ?>
	<h1>Title in multiple-lines comment block.</h1>
<?php } else {*/ ?>
	<h1>Title not in comment block.</h1>
<?php //} ?>
0 Likes

#2

reported on https://github.com/sublimehq/Packages/issues/3540

0 Likes