aik099 / CodingStandard

The PHP_CodeSniffer coding standard I'm using on all of my projects
BSD 3-Clause "New" or "Revised" License
5 stars 2 forks source link

Magnetic inline comments #17

Open aik099 opened 10 years ago

aik099 commented 10 years ago

Currently an inline comment must be placed right above code line to be valid. This creates a problems, where you need to mark a piece of code with comments, e.g.

echo '';

// CUSTOM: begin
$this_code = 5;
// CUSTOM: end (warning here)

echo 'something';

I propose this:

aik099 commented 9 years ago

Current implementation adds empty line before comment and not after it during auto-fixing!