On Wednesday 30 July 2025 08:40:52 (+02:00), Alexandre Daubois wrote:

> > Btw. is_primitive() was not a thing last time I looked. It would be great > > though to have the combined test of is_scalar() and is_null() in a single
> > function call.
> > I like the idea.
Thanks.

> Would it have its place in this RFC? I feel like it
> could with a separate vote, but maybe this would require its own RFC.

Nah, at least me would not put it in there. But maybe after that RFC is done, we probably should revisit the idea.

With representable as float, is_primitive() could get even more clarity apart from the ordinary type test, and probably buy into the commons mirrored in the rel. recent JSON Path Internet-RFC JSON value mindset, which was with an early PHP implementation since it's beginning ca. 20 years or so ago. If we're able to capture such longtime wisdom within the language it would be a testament to software engineering in web/phptech and could become a beautiful example of unveiling true ergonomics.

My 2 cents

-- hakre

Reply via email to