Strange behaviour with locale decimal point and type casting
<p>Locale is set to <code>setlocale(LC_ALL, 'ru_RU.UTF-8')</code>
In Russia, decimal point is <code>,</code>.</p>

<p>I'm getting string input (for example, <code>11,25</code>).
When I'm typecasting it to double <code>$double = (double)$double;</code> I'm loosing precision.</p>

<pre><code>setlocale(LC_ALL, 'ru_RU.UTF-8');

$input = '11,25';
var_dump((double)$input); //11

$linfo = localeconv();
$input = '11'.$linfo['decimal_point'].'25';
var_dump((double)$input); //11

$input = '11.25';
var_dump((double)$input); //11,25
</code></pre>

<p>So, as I can see locale effects only view.
Does it mean that I should always <code>str_replace(array(',','.'), '.', $input)</code> before operating decimal values?</p>
