Thread overview | |||||
---|---|---|---|---|---|
|
January 09, 2011 [phobos] phobos commit, revision 2292 | ||||
---|---|---|---|---|
| ||||
phobos commit, revision 2292 user: andrei msg: conditionalized unittest for round http://www.dsource.org/projects/phobos/changeset/2292 paths changed: U trunk/phobos/std/math.d |
January 09, 2011 [phobos] phobos commit, revision 2292 | ||||
---|---|---|---|---|
| ||||
Posted in reply to dsource.org | On 1/9/2011 12:43 PM, dsource.org wrote:
> phobos commit, revision 2292
>
>
> user: andrei
>
> msg:
> conditionalized unittest for round
>
> http://www.dsource.org/projects/phobos/changeset/2292
>
> paths changed:
> U trunk/phobos/std/math.d
>
Poke.. don beat you to it.. take a look at the resulting code:
version(Posix)
{
unittest
{
version(Posix)
{
assert(lround(0.49) == 0);
assert(lround(0.5) == 1);
assert(lround(1.5) == 2);
}
}
}
|
January 09, 2011 [phobos] phobos commit, revision 2292 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Brad Roberts | I'll remove my stuff. Everyone, carry on. :o)
Andrei
On 1/9/11 2:45 PM, Brad Roberts wrote:
> On 1/9/2011 12:43 PM, dsource.org wrote:
>> phobos commit, revision 2292
>>
>>
>> user: andrei
>>
>> msg:
>> conditionalized unittest for round
>>
>> http://www.dsource.org/projects/phobos/changeset/2292
>>
>> paths changed:
>> U trunk/phobos/std/math.d
>>
>
> Poke.. don beat you to it.. take a look at the resulting code:
>
> version(Posix)
> {
> unittest
> {
> version(Posix)
> {
> assert(lround(0.49) == 0);
> assert(lround(0.5) == 1);
> assert(lround(1.5) == 2);
> }
> }
> }
> _______________________________________________
> phobos mailing list
> phobos at puremagic.com
> http://lists.puremagic.com/mailman/listinfo/phobos
|
Copyright © 1999-2021 by the D Language Foundation