Bug Of pow in std.math

2010-06-30 Thread sins666
I found a Bug.The bug lives in function of pow in std.math.

When wake up the bug that, we select value of minus to second
argument of pow.
And happen the object.Error: Integer Divide by Zero error.

I think that is a Bug. Is it?


[Issue 4409] New: to!double(-nan) throws

2010-06-30 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=4409

   Summary: to!double(-nan) throws
   Product: D
   Version: D2
  Platform: Other
OS/Version: Windows
Status: NEW
  Severity: normal
  Priority: P2
 Component: Phobos
AssignedTo: nob...@puremagic.com
ReportedBy: dsim...@yahoo.com


--- Comment #0 from David Simcha dsim...@yahoo.com 2010-06-30 07:32:09 PDT ---
import std.conv;

void main() {
auto foo = to!double(nan);  // Works
auto bar = to!double(-nan); // Throws
}

std.conv.ConvError: std.conv(659): Can't convert value `-nan' of type
const(char)[] to type double

It's important that the string -nan get converted properly to a NaN so that
floating point numbers output to strings by writeln() can be read back
properly.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---


Re: Bug Of pow in std.math

2010-06-30 Thread Simen kjaeraas

sins666 d-bugm...@puremagic.com wrote:


I found a Bug.The bug lives in function of pow in std.math.

When wake up the bug that, we select value of minus to second
argument of pow.
And happen the object.Error: Integer Divide by Zero error.

I think that is a Bug. Is it?


I would recommend discussing such in digitalmars.D.learn.

Now, I'm not able to recreate this. Am I right to understand
it to be:

std.math.pow( 5, -3 ); ?

If not, would you please post code that triggers the bug?

--
Simen


[Issue 3155] LDC2 support for druntime

2010-06-30 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=3155


Jacob Carlborg d...@me.com changed:

   What|Removed |Added

 CC||d...@me.com


--- Comment #9 from Jacob Carlborg d...@me.com 2010-06-30 12:49:14 PDT ---
Why not just use the approach Tango uses?

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---


[Issue 4401] auto functions cannot be inner functions

2010-06-30 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=4401


Leopold Walkling leopold_walkl...@web.de changed:

   What|Removed |Added

 CC||leopold_walkl...@web.de


--- Comment #2 from Leopold Walkling leopold_walkl...@web.de 2010-06-30 
12:58:50 PDT ---
While skimming parser.c I noticed that the auto keyword is treated like a
storage specifier, so this one is allowed:

auto void bar() { }

The spec says nothing about this case, but it seems nonsensical.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---


[Issue 3934] Some untidy attributes

2010-06-30 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=3934



--- Comment #4 from bearophile_h...@eml.cc 2010-06-30 13:14:48 PDT ---
One from Leopold Walkling, this compiles:

auto void main() {}

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---


[Issue 3934] Some untidy attributes

2010-06-30 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=3934



--- Comment #5 from Stewart Gordon s...@iname.com 2010-06-30 16:33:29 PDT ---
I certainly call that a bug.

Partly a consequence of auto being an attribute rather than a placeholder for a
type, though this seems to be partly for backward compatibility with the old
meaning of auto.  Either way, it's an inapplicable attribute and one that ought
not to be accepted.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---


[Issue 3872] std.algorithm.filter could become bidirectional if its input range is bidir

2010-06-30 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=3872


David Simcha dsim...@yahoo.com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dsim...@yahoo.com
 Resolution||FIXED


--- Comment #1 from David Simcha dsim...@yahoo.com 2010-06-30 19:58:43 PDT ---
Fixed SVN.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---


[Issue 2627] std.traits.hasAliasing reports true for static arrays

2010-06-30 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=2627


David Simcha dsim...@yahoo.com changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 CC||dsim...@yahoo.com
 Resolution||FIXED


--- Comment #1 from David Simcha dsim...@yahoo.com 2010-06-30 20:28:04 PDT ---
Fixed SVN.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---


Re: Bug Of pow in std.math

2010-06-30 Thread sins666
== Quote from Simen kjaeraas (simen.kja...@gmail.com)'s article
 sins666 d-bugm...@puremagic.com wrote:
  I found a Bug.The bug lives in function of pow in std.math.
 
  When wake up the bug that, we select value of minus to second
  argument of pow.
  And happen the object.Error: Integer Divide by Zero error.
 
  I think that is a Bug. Is it?
 I would recommend discussing such in digitalmars.D.learn.
 Now, I'm not able to recreate this. Am I right to understand
 it to be:
 std.math.pow( 5, -3 ); ?
 If not, would you please post code that triggers the bug?

import std.math;
import std.stdio;

void main()
{
writeln(pow(5, 2)); // 25
writeln(pow(5, 0)); // 1
writeln(pow(5, -3)); // object.Error: Integer Divide by Zero
}

And dmd version is 2.047.
Was I mistake in my source.or bug?


[Issue 3155] LDC2 support for druntime

2010-06-30 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=3155



--- Comment #10 from Sean Kelly s...@invisibleduck.org 2010-06-30 22:42:56 
PDT ---
Druntime used to, but it's a very complicated structure.  And even the Tango
runtime was intended to originally provide only a template.  The hope was that
compiler writers would eventually each maintain their own runtime, and it
doesn't really make sense that every compiler runtime would live in the same
SVN.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---