Hi!

> You can take a look at the tests to get a feel for what it’s like:
> 
> https://github.com/php/php-src/pull/5308/files
> 
> Multiple conditions are possible:
> 
> ```
> 
> return $day switch {
> 
>     1, 7 => false,
> 
>     2, 3, 4, 5, 6 => true,
> 
> };

I'm still not sure why if we're calling it "switch" it can't use
traditional switch structure. If it uses something else, it must be
called by some other keyword, it's not a good idea to have two "switch"
constructs in the language with completely different syntax.


-- 
Stas Malyshev
smalys...@gmail.com

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to