[TYPO3-core] Change CGL for string concatenation
Markus Klein
klein.t3 at reelworx.at
Sun Dec 7 12:04:34 CET 2014
We already have many operators in front:
If (
$var1
&& $var 2
)
$a = $b
? 'abc'
: 'def';
Kind regards
Markus
------------------------------------------------------------
Markus Klein
TYPO3 CMS Active Contributors Team Member
> -----Original Message-----
> From: typo3-team-core-bounces at lists.typo3.org [mailto:typo3-team-core-
> bounces at lists.typo3.org] On Behalf Of Jigal van Hemert
> Sent: Sunday, December 07, 2014 12:34 AM
> To: typo3-team-core at lists.typo3.org
> Subject: Re: [TYPO3-core] Change CGL for string concatenation
>
> Hi,
>
> On 05/12/2014 20:41, Steffen Müller wrote:
> > Am 05.12.2014 um 00:03 schrieb Frank Nägler:
> >> In the core we have a mix of both implementations. The dot at the
> beginning is clearer and can immediately recognized as a concatenation.
> >
> > It's so obvious:
> >
> >
> > $foo = array(
> > $bar,
> > $baz .
> > $buz
> > );
>
> No, this one would be:
>
> $foo = array(
> $bar,
> $baz . $buz
> );
>
> But even if we had looooong strings it would be:
>
> $foo = array(
> $bar,
> 'The really long text in a string that is longer than the usual ' .
> 'margin set in editors and IDEs.'
> );
>
> (which looks different from your first example)
>
> >
> > vs.
> >
> > $foo = array(
> > $bar,
> > $baz
> > . $buz
> > );
>
> Still, it's too trivial to discuss. Both are easy to read, and there are issues that
> really need time and effort.
>
> If you really need to change this, the position of all operators in expressions
> that span multiple lines have to be changed. In most IDEs you can only set
> the behaviour for all operators and not per operator.
>
> --
> Jigal van Hemert
> TYPO3 CMS Active Contributor
>
> TYPO3 .... inspiring people to share!
> Get involved: typo3.org
> _______________________________________________
> Before posting to this list, please have a look to the posting rules on the
> following websites:
>
> http://typo3.org/teams/core/core-mailinglist-rules/
> http://typo3.org/development/bug-fixing/diff-and-patch/
> _______________________________________________
> TYPO3-team-core mailing list
> TYPO3-team-core at lists.typo3.org
> http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-team-core
More information about the TYPO3-team-core
mailing list