Is cool and all, but are we going to assume auto boxing here or are we going with no more primitives at all? I feel if we still want real primitives(which I assume we do), something like
$var = new String('Even more hella clever string here');
$var->someStringMethodHere();
is a better approach than automatically auto boxing all scalars into objects. That way we have both scalar objects and primitives still.
Perhaps instead even better could be having the 'scalar object' not be a real object at all, but instead the access before in the first example I provided instead be a bit of syntactic sugar for
someStringMethodHere('hella clever string here');
Something like that would be great. Without generics and such I don't think we really want them to be objects cause we wouldn't want something like
Because then there's literally no point to using stdClass as a type hint since everything would be one.
Also I just want a real god damn array. None of this map masquerading as an array bullshit. Sometimes I just need some integers one after the other in memory and not have to worry about if someone used a string as an index by accident.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Are you proposing this work similar to Java with auto boxing? I mean something like
Is cool and all, but are we going to assume auto boxing here or are we going with no more primitives at all? I feel if we still want real primitives(which I assume we do), something like
is a better approach than automatically auto boxing all scalars into objects. That way we have both scalar objects and primitives still.
Perhaps instead even better could be having the 'scalar object' not be a real object at all, but instead the access before in the first example I provided instead be a bit of syntactic sugar for
Something like that would be great. Without generics and such I don't think we really want them to be objects cause we wouldn't want something like
Because then there's literally no point to using stdClass as a type hint since everything would be one.
Also I just want a real god damn array. None of this map masquerading as an array bullshit. Sometimes I just need some integers one after the other in memory and not have to worry about if someone used a string as an index by accident.