wrote in message news:4b55eed1-8656-ff70-e4e9-ad5e40213...@rhsoft.net...
Am 29.12.2017 um 00:21 schrieb Larry Garfield:
Correct. Union types I've always seen presented as offering both union
and
intersection. There are cases where union is great, and where it's kinda
silly. There are case
On 12/29/2017 12:21 AM, Larry Garfield wrote:
> On Wednesday, December 27, 2017 3:50:54 AM CST Rowan Collins wrote:
>> On 26 December 2017 18:35:29 GMT+00:00, "li...@rhsoft.net"
> wrote:
>>> Am 26.12.2017 um 19:18 schrieb Larry Garfield:
If I may, I think the argument has always been that
>>
On 29 December 2017 12:08:16 GMT+00:00, Fleshgrinder
wrote:
>What is the use case for `int|float`? I mean, if f is able to process a
>`float` than f is able to process an `int` and since `int` is already
>automatically changed to a `float`, well, you're done.
I think it is somewhat tedious if we
On 12/29/2017 1:26 PM, Rowan Collins wrote:
> On 29 December 2017 12:08:16 GMT+00:00, Fleshgrinder
> wrote:
>> What is the use case for `int|float`? I mean, if f is able to
>> process a `float` than f is able to process an `int` and since
>> `int` is already automatically changed to a `float`, wel
Am 29.12.2017 um 09:04 schrieb Tony Marston:
wrote in message news:4b55eed1-8656-ff70-e4e9-ad5e40213...@rhsoft.net...
Am 29.12.2017 um 00:21 schrieb Larry Garfield:
Correct. Union types I've always seen presented as offering both
union and
intersection. There are cases where union is great
> On 29 Dec 2017, at 19:56, Fleshgrinder wrote:
>
>> On 12/29/2017 1:26 PM, Rowan Collins wrote:
>> On 29 December 2017 12:08:16 GMT+00:00, Fleshgrinder
>> wrote:
>>> What is the use case for `int|float`? I mean, if f is able to
>>> process a `float` than f is able to process an `int` and since
On Friday, December 29, 2017 8:20:14 AM CST Stephen Reay wrote:
> > On 29 Dec 2017, at 19:56, Fleshgrinder wrote:
> >> On 12/29/2017 1:26 PM, Rowan Collins wrote:
> >> On 29 December 2017 12:08:16 GMT+00:00, Fleshgrinder
> >>
> >> wrote:
> >>> What is the use case for `int|float`? I mean, if f i
Am 29.12.2017 um 13:08 schrieb Fleshgrinder:
What is the use case for `int|float`? I mean, if f is able to process a
`float` than f is able to process an `int` and since `int` is already
automatically changed to a `float`, well, you're done
just read the mass of bugreports caused by float answ
On Fri, Dec 29, 2017 at 1:08 PM, Fleshgrinder wrote:
> On 12/29/2017 12:21 AM, Larry Garfield wrote:
> > On Wednesday, December 27, 2017 3:50:54 AM CST Rowan Collins wrote:
> >> On 26 December 2017 18:35:29 GMT+00:00, "li...@rhsoft.net"
> > wrote:
> >>> Am 26.12.2017 um 19:18 schrieb Larry Garfi
Am 29.12.2017 um 16:37 schrieb Nikita Popov:
Regarding the union type RFCs, from what I remember, one of my personal
issues with it were the complex rules involving scalar type unions in weak
typing mode. It's non-trivial to decide what a value should be casted to if
it does not have the correc
On 12/29/2017 4:37 PM, Nikita Popov wrote:
> int|float is the natural type of numeric operations in PHP. Integers
> automatically overflow into floating point numbers, so signatures using int
> in conjunction with numeric operations are somewhat problematic.
>
> Having an explicit number type also
On 12/29/2017 4:09 PM, li...@rhsoft.net wrote:
>
> Am 29.12.2017 um 13:08 schrieb Fleshgrinder:
>> What is the use case for `int|float`? I mean, if f is able to process a
>> `float` than f is able to process an `int` and since `int` is already
>> automatically changed to a `float`, well, you're do
Am 29.12.2017 um 18:18 schrieb Fleshgrinder:
On 12/29/2017 4:09 PM, li...@rhsoft.net wrote:
Am 29.12.2017 um 13:08 schrieb Fleshgrinder:
What is the use case for `int|float`? I mean, if f is able to process a
`float` than f is able to process an `int` and since `int` is already
automatically
Am 29.12.2017 um 18:13 schrieb Fleshgrinder:
Why exactly is it necessary to support weak mode together with unions
and intersections? It is obviously unclear in many situations what
should happen, so why not simply bail like in strict mode?
is also a good enough way to handle it now as we hav
On 12/29/2017 6:21 PM, li...@rhsoft.net wrote:
> no, when i accept "int|float" i don't get something converted at all and
> i can handle the cases different - when it#s silently casted to a float
> i have no way to know it was a int at call time
>
Again, obviously, the question remains, why would
Hi all,
On 26.12.17 16:56, Sebastian Bergmann wrote:
Am 26.12.2017 um 16:46 schrieb li...@rhsoft.net:
would you mind to explain this?
"Foo|Bar", "array|string", etc. (still) make no sense to me.
"scalar" makes sense to me although it is but an alias for
"bool|float|int|string".
I followed
Am 29.12.2017 um 18:24 schrieb Fleshgrinder:
On 12/29/2017 6:21 PM, li...@rhsoft.net wrote:
no, when i accept "int|float" i don't get something converted at all and
i can handle the cases different - when it#s silently casted to a float
i have no way to know it was a int at call time
Again,
Am 29.12.2017 um 18:29 schrieb Markus Fischer:
On 26.12.17 16:56, Sebastian Bergmann wrote:
Am 26.12.2017 um 16:46 schrieb li...@rhsoft.net:
would you mind to explain this?
"Foo|Bar", "array|string", etc. (still) make no sense to me.
"scalar" makes sense to me although it is but an alias f
> On 30 Dec 2017, at 00:24, Fleshgrinder wrote:
>
> Again, obviously, the question remains, why would you care?
Really, that's what's obvious to you?
What's obvious to *me* is that if a method accepts two different types of
parameters, you'd want to know which was passed in.
--
PHP Internals
19 matches
Mail list logo