Updated the article, thanks! Wouldn't really say that's a stupid addon, though, the expected way to use readonly properties from other languages is assign the value directly (impossible in PHP) or inside the constructor (or other mechanisms that are only available during object creation, like C# initializers etc.).
I like it as well, recently had one use case where it would have been the best solution, sadly php-cs-fixer chokes on that so I had to do it with property hooks.
Same, but given how seriously they take BC breaks, I don't really see it happening. Well, at least we have mature tooling to avoid having horrible code in production code-bases.
Well, that's historical, if PHP was being designed today, I think a lot of the things would look very different. As everything since version 7.x, this is a step in the right direction of making the language modern and safer to use.
Like, this is still PHP, both of these are equally valid:
<?php
function hello(string $name): string {
return "Hello, {$name}!";
}
function hello($name) {
return "Hello, $name!";
}
So anything that makes it possible to write a good, clean code is a great addition, IMO.
Asi bude lepší použít můj Lemmy účet (@rikudou@lemmings.world), tohle je můj blog a vesměs není použitelný na komentáře mimo moje vlastní příspěvky, nic jiného se mi tu nezobrazuje.
I must admit I always forget XMPP exists (which seems to be a common trend). It doesn't support e2e, right? That doesn't really make it useful in modern times anymore (in my opinion).
Thanks! I'm not aware that any Fediverse software actually allows that, but hey, might be worth testing out what each software thinks about liking a like.
Kinda, but in a really weird way, nothing is getting standardized and everything is a de-facto standard (or not, especially Mastodon devs don't really care about the rest of Fediverse), which is not good for development.
One of my favourite xkcd images! And yeah, creating another competing standard would suck, what's needed is more of a slow evolution towards a sane standard.
Edit: Didn't notice your edit before. Well, I think sending private messages has been part of social media when before it was called social media, so missing that functionality feels like it would unnecessarily hold the Fediverse back.
As for encryption, I believe it is needed in some form because stuff like GDPR and other privacy laws might as well destroy the Fediverse if some bureaucrat decides they want to look into it.
I'd argue there's no reason ever to actually use it in production. This is such a horrible hack that it has no place outside dicking around for fun.
Updated the article, thanks! Wouldn't really say that's a stupid addon, though, the expected way to use readonly properties from other languages is assign the value directly (impossible in PHP) or inside the constructor (or other mechanisms that are only available during object creation, like C# initializers etc.).
Oh, right, that didn't occur to me. Well, guess I got used to it eventually. But yeah, the
...already does way too many things in PHP.I would've preferred
?, but...is fine, IMO.I like it as well, recently had one use case where it would have been the best solution, sadly php-cs-fixer chokes on that so I had to do it with property hooks.
Same, but given how seriously they take BC breaks, I don't really see it happening. Well, at least we have mature tooling to avoid having horrible code in production code-bases.
Well, that's historical, if PHP was being designed today, I think a lot of the things would look very different. As everything since version 7.x, this is a step in the right direction of making the language modern and safer to use.
Like, this is still PHP, both of these are equally valid:
So anything that makes it possible to write a good, clean code is a great addition, IMO.
Asi bude lepší použít můj Lemmy účet (@rikudou@lemmings.world), tohle je můj blog a vesměs není použitelný na komentáře mimo moje vlastní příspěvky, nic jiného se mi tu nezobrazuje.
I'll check it out, thanks!
I must admit I always forget XMPP exists (which seems to be a common trend). It doesn't support e2e, right? That doesn't really make it useful in modern times anymore (in my opinion).
Thanks! I'm not aware that any Fediverse software actually allows that, but hey, might be worth testing out what each software thinks about liking a like.
Kinda, but in a really weird way, nothing is getting standardized and everything is a de-facto standard (or not, especially Mastodon devs don't really care about the rest of Fediverse), which is not good for development.
Taky veselé Velikonoce! :)
One of my favourite xkcd images! And yeah, creating another competing standard would suck, what's needed is more of a slow evolution towards a sane standard.
Edit: Didn't notice your edit before. Well, I think sending private messages has been part of social media when before it was called social media, so missing that functionality feels like it would unnecessarily hold the Fediverse back.
As for encryption, I believe it is needed in some form because stuff like GDPR and other privacy laws might as well destroy the Fediverse if some bureaucrat decides they want to look into it.
I didn't! But now I do :) Joined!
By the way, as mentioned in the post, if anyone can recommend a good algorithm to calculate Easter, let me know!
You mean the blog post I wrote myself and published on my ActivityPub enabled blog? That kind of "spam bot"?