ag0aep6g wrote:

On 06/19/2017 10:04 AM, ketmar wrote:
core.math.rndtonl is declared as this:
extern (C) real rndtonl(real x);

Is rndtonl a Digital Mars C thing?

yes, it looks like DMC library function. thus, is should be versioned out on non-DMC builds. another bug. ;-)

It has no implementation in druntime, and I get an undefined reference when I try to call it on Linux.

It compiles on Windows (wine, -m32), but only ever returns -nan.

If this is the same function: <http://www.digitalmars.com/rtl/fltpnt.html#rndtol>, then it should return a C long, which I guess is a D int on 32 bits. And surprise: that works.

no, there is `rndtol()` and `rndtonl()` in `core.math`,  they are different 
functions.

also, `rndtol()` should return D `long` (i.e. 64 bit value). at least this is what `core.math` says.

Reply via email to