Athari / YaLinqo

Yet Another LINQ to Objects for PHP [Simplified BSD]
https://athari.github.io/YaLinqo
BSD 2-Clause "Simplified" License
439 stars 39 forks source link

Fix php 7.2 unset cast deprecated warning #23

Closed lucasjsoliveira closed 6 years ago

lucasjsoliveira commented 6 years ago

This fix project compatibility with php 7.2, at least in my use case. This was the main deprecated warning I got after upgrading to 7.2, and acording to the docs, produces the same result.

Athari commented 6 years ago

@lucasjsoliveira Thanks for the fix! No idea why I used this weird syntax in the first place.


Huh, create_function is deprecated too, in favor of eval and closures. How am I supposed to cache the evaluated string code now? Switching to eval will kill what's left of performance when using string lambdas. And they still haven't added arrow functions, so it's not like I can just drop the support for string lambdas and forget this abomination ever existed.

HHVM seems to be dead... It's PHP 5.6 and Composer on CI server managed to get PHPUnit 6.5.2 when asked to get ~4.6. What the heck? Ugh, I'll just drop support for HHVM, I don't think anyone cares.