in reply to cos (100000000.0)

It seems to be just a normal floating point error.
and why it does not truncate it to what it knows it is the last precision it can correctly calculate?

To know how many digits it can calculate correctly it would have to track rounding errors, resulting a large performance penalty. So it doesn't do that, and neither does C++ or Java.

C++ just uses a much more defensive default precision.

Perl 6 - links to (nearly) everything that is Perl 6.