[Neos] CGL Questions
Rens Admiraal
rens.admiraal at typo3.org
Sun Oct 13 15:26:52 CEST 2013
Hey guys,
I did some tries with the QA team a while ago to get the QA-Teams sniff
packages compatible with Flow. It seems like they didn't do anything
with it yet, so I'll do another try in some lost minutes... But more
important I think it's a good thing if we start running the codesniffs
regularly.
For that I'll update my forked sniff packages and make sure they reflect
the CGL (ofc. using the stuff from the QA team as much as possible).
When we've a set that's working for us it's probably also easier to get
it upstream with the QA team.
Some issues currently found by the sniffer are not yet covered by the
CGL though, so I would like to use this thread to discuss those.
* Usage of functions in foreach / if / for / switch statements
Do we allow this? For example:
foreach ($this->getSomeArray() as $v) { ....
* Do we allow empty catch statements?
Example:
} catch (\Exception $e) { // just some comments or nothing }}
* How do we format use statements?
Will we use 1 use statement like:
use Class 1,
Class 2;
Or do we add all use statements on a new line?
* We have some auto generated / 3rd party classes hidden in the source,
how to sniff them?
Here I mean for example the EelParsers which are auto generated, or the
Security Randomizer class. We can ignore them in the rule set, but I
don't like excluding by classname. It would be better if we could for
example use a fixed folder path inside packages to put such classes,
which we can then ignore
Looking forward to some feedback, and feel free to add more CGL stuff
that needs discussion ;-)
Greetz,
Rens
More information about the Neos
mailing list