Re: [PHP-DEV] RFC: var_export - short syntax for array

2019-08-21 Thread Benjamin Morel
> > There are other issues with the format besides just the long array syntax. > E.g. opening bracket on same line? Indentation? For the record, I have a userland implementation of var_export() that does all of this: - (object) array export of stdClass for PHP < 7.3 - short array syntax - bracke

Re: [PHP-DEV] RFC: var_export - short syntax for array

2019-08-21 Thread Lynn
On Wed, Aug 21, 2019 at 10:25 AM Andreas Hennings wrote: > Avoiding disruption is indeed a concern. > As an example, Drupal 7 features module uses a custom variation of > var_export() to write configuration to code, which is then typically > tracked in git. > Hi Andreas, If the output is being

Re: [PHP-DEV] RFC: var_export - short syntax for array

2019-08-21 Thread Andreas Hennings
Avoiding disruption is indeed a concern. As an example, Drupal 7 features module uses a custom variation of var_export() to write configuration to code, which is then typically tracked in git. I am not sure if changing the native var_export() would have an impact here, and anyway the module can be

Re: [PHP-DEV] RFC: var_export - short syntax for array

2019-08-20 Thread Влад Макин
Thanks for the feedback! I will back with improved version of RFC. вт, 20 авг. 2019 г., 23:01 Sara Golemon : > On Tue, Aug 20, 2019 at 1:05 PM Влад Макин wrote: > >> I would like to propose a little change in var_export function behavior. >> For today, this function returns string representatio

Re: [PHP-DEV] RFC: var_export - short syntax for array

2019-08-20 Thread Sara Golemon
On Tue, Aug 20, 2019 at 1:05 PM Влад Макин wrote: > I would like to propose a little change in var_export function behavior. > For today, this function returns string representation of array in old > style with “array” keyword: > > var_export([]); // array() > > I think it would be better if the

[PHP-DEV] RFC: var_export - short syntax for array

2019-08-20 Thread Влад Макин
Hello! I would like to propose a little change in var_export function behavior. For today, this function returns string representation of array in old style with “array” keyword: var_export([]); // array() I think it would be better if the function returned array representation in modern square