Skip to content

Blank line not enforced after control structure if comment on same line as closing brace #1817

Closed
@josephzidell

Description

@josephzidell
<?php

$true = true;
if ($true) {
	echo 'hi 1';
}
if ($true) {
	echo 'hi 2';
}//end if
if ($true) {
	echo 'hi 3';
}

Throws an error after the first if, but not after the second. When there's a closing comment, a blank line is not enforced.

This likewise affects foreachs etc...

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions