moodlehq / moodle-cs

Moodle Coding Style

Home Page:https://github.com/moodlehq/moodle-cs

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Detect various spacing issues in function declarations

stronk7 opened this issue · comments

This is about, exclusively, detect spacing issues in function/method declarations. Some cases (there may be more):

  • No space between function name and open parenthesis.
  • No space between close parenthesis and the return type colon.
  • Space between the return type colon and the return type.
  • Space before the curly brackets.
  • ...

aka, correct:

function function_name(...params): ?type {