FYI it needs some extra attention because in case of an `if` statement you
do not want a space before.. (at least that's what I think)... or in case
of an assignment you need the space before.
if((int)$var) {
}
$var = (int) $var2;
Τη Παρασκευή, 28 Δεκεμβρίου 2018 - 5:07:21 μ.μ. UTC+2, ο χρήστης Georgios
Mponos έγραψε:
>
> Hello,
>
> I am writing this thread in order to notify you about casting issues that
> got into my attention. I think that PSR-12 is not dealing with how the
> casting should be styled
>
> https://github.com/squizlabs/PHP_CodeSniffer/pull/2331
>
> Also one more thing that could be useful is this:
>
> https://github.com/doctrine/coding-standard/pull/100
>
> I believe that PSR-12 should deal with spaces inside of cast and spaces
> before the cast.
>
> Regards,
>
--
You received this message because you are subscribed to the Google Groups "PHP
Framework Interoperability Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/php-fig/5f8c78e9-a9a0-4b8a-9722-79bbf337acfb%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.