Re: [PHP-DEV] Re: Straw poll: Places to allow function calls in constant expressions

2020-02-22 Thread tyson andre
> The original motivation was, IIRC, to initialize class constants with an > expression. > Following KISS, I feel we should constrain our efforts to that scope, and > that's how I voted: > "Yes" on class constants and static members, "No" on everything else. I'd also personally found the

Re: [PHP-DEV] Re: Straw poll: Places to allow function calls in constant expressions

2020-02-19 Thread Mike Schinkel
> On Feb 19, 2020, at 2:00 PM, Bishop Bettini wrote: > > Consequently, the only way to safely initialize class constants and static > members is at run-time, and I can only think of one way to do it. Apologies > if this has already been suggested: taking a cue from C#, a static class >

Re: [PHP-DEV] Re: Straw poll: Places to allow function calls in constant expressions

2020-02-19 Thread Bishop Bettini
On Wed, Feb 19, 2020 at 12:58 PM tyson andre wrote: > Hi internals, > > > I've created a straw poll at > https://wiki.php.net/rfc/calls_in_constant_expressions_poll , to measure > interest in allowing calls in different types of constant expressions. > > If there aren't any problems with the

[PHP-DEV] Re: Straw poll: Places to allow function calls in constant expressions

2020-02-19 Thread tyson andre
Hi internals, > I've created a straw poll at > https://wiki.php.net/rfc/calls_in_constant_expressions_poll , to measure > interest in allowing calls in different types of constant expressions. > If there aren't any problems with the poll structure or rules preventing > creating a poll, I was

Re: [PHP-DEV] Re: Straw poll: Places to allow function calls in constant expressions

2020-02-16 Thread tyson andre
> > I've created a straw poll at > > https://wiki.php.net/rfc/calls_in_constant_expressions_poll , > > to measure interest in allowing calls in different types of constant > > expressions. > > I've yet to make my mind up for most circumstances, although I'm leaning towards a general "No". > >

[PHP-DEV] Re: Straw poll: Places to allow function calls in constant expressions

2020-02-16 Thread Mark Randall
On 17/02/2020 02:08, tyson andre wrote: I've created a straw poll at https://wiki.php.net/rfc/calls_in_constant_expressions_poll , to measure interest in allowing calls in different types of constant expressions. I've yet to make my mind up for most circumstances, although I'm leaning towards