On 20/01/2021 20:21, Claude Pache wrote:
Or short_var_export() could just reuse the existing __debugInfo() magic method (which is already used by both var_dump() and print_r, but not by var_export()). The programmer would just need to make sure that __set_state() can consume the array produced by __debugInfo().
This is an interesting question to explore, but I don't follow how this relates to my previous e-mail. I'm saying that having print_r, var_dump, var_export, and var_export_short (or whatever we call it) all in one language is more confusing than helpful.
Regards,
--
Rowan Tommins
[IMSoP]