CamilleDrapier (Camille Drapier)
- Login: CamilleDrapier
- Registered on: 03/07/2020
- Last sign in: 11/11/2020
Issues
| open | closed | Total | |
|---|---|---|---|
| Assigned issues | 0 | 0 | 0 |
| Reported issues | 0 | 1 | 1 |
Activity
03/07/2020
-
01:22 PM Ruby Bug #16677: Negative integer powered (**) to a float number results in a complex
- Oh sorry, I just notice that this is an expected behaviour in the documentation (example) given in Integer.
I guess the to-i attribute assignment is a bit confusing that it changes the behaviour but probably not a bug! -
05:15 AM Ruby Bug #16677 (Closed): Negative integer powered (**) to a float number results in a complex
- Not sure if this is an unexpected behavior.
This works as I expect:
```
-2 ** 2.2 # => -4.59479341998814
```
But when I change the code a bit, it gives me a complex:
```ruby
-2.to_i ** 2.2 # => (3.717265962412589+2.7007518...