Ancestors

Toot

Written by dseguy on 2025-01-10 at 17:45

[#]PHP trick question, for the Friday developer: where do you put the parenthesis in a new call:

[#]phptip #php trick

https://php-tips.readthedocs.io/en/latest/tips/new_and_parenthesis.html

=> View attached media

=> More informations about this toot | More toots from dseguy@phpc.social

Descendants

Written by bob.php :veritrek_gold: on 2025-01-10 at 17:58

@dseguy the last 3 samples on your blog i would written all of them as $Obj = (new $Obj); myself. that is my rule when magic crap starts coming into play for the class name lol.

=> More informations about this toot | More toots from bobmagicii@phpc.social

Written by dseguy on 2025-01-10 at 18:10

@bobmagicii Spoken like a true veteran :elephpant:

=> More informations about this toot | More toots from dseguy@phpc.social

Written by bob.php :veritrek_gold: on 2025-01-11 at 00:27

@dseguy that and im just a huge fan of excess parens. it actually saved me once back during the php 7.0 transition (i think it was) because the order of operations changed for a few things. but not for me. because i am crazy.

=> More informations about this toot | More toots from bobmagicii@phpc.social

Proxy Information
Original URL
gemini://mastogem.picasoft.net/thread/113805302844962357
Status Code
Success (20)
Meta
text/gemini
Capsule Response Time
307.771965 milliseconds
Gemini-to-HTML Time
1.025764 milliseconds

This content has been proxied by September (ba2dc).