[Issue 8441] mixin containing template functions causes compiler errors

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=8441


jfanati...@gmx.at changed:

   What|Removed |Added

 Blocks|9347|
   Severity|blocker |major


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


[Issue 10141] wrong error message with Tuple!(int) : Error: static assert Cannot put a char[] into a Appender!(string)

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10141



--- Comment #7 from github-bugzi...@puremagic.com 2013-07-15 00:19:47 PDT ---
Commits pushed to master at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/8c5cce3e6ffd63ad3af23caf2e15ea7a3eabeea5
fix Issue 10141 - wrong error message with Tuple!(int) : Error: static assert
Cannot put a char[] into a Appender!(string)

Essentially it's bad code if it branches based on the condition `global.errors
!= 0`.

https://github.com/D-Programming-Language/dmd/commit/390a9340cad6f9c44757cd4782792b08d95a56ba
Merge pull request #2346 from 9rnsr/fix10141

Issue 10141 - wrong error message with Tuple!(int) : Error: static assert
Cannot put a char[] into a Appender!(string)

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


[Issue 10644] New: Win64: wrong code when passing arguments through ...

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10644

   Summary: Win64: wrong code when passing arguments through ...
   Product: D
   Version: D2
  Platform: All
OS/Version: All
Status: NEW
  Keywords: wrong-code
  Severity: normal
  Priority: P2
 Component: DMD
AssignedTo: nob...@puremagic.com
ReportedBy: r.sagita...@gmx.de


--- Comment #0 from Rainer Schuetze r.sagita...@gmx.de 2013-07-15 00:25:39 
PDT ---
An example from the unittest of std.outbuffer:

import std.outbuffer;

void main()
{
OutBuffer buf = new OutBuffer();

buf.printf(%d, 42);
assert(buf.toString() == 42);
}

build and run for win64 throws the assertion.

Checking the implementation of OutBuffer.printf shows that there is no uniform
abstraction for passing arguments to printf(string format, ...) anyway, and the
Win64 version seems broken.

This also applies to stream.printf.

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


[Issue 10633] Win64: wrong codegen with %=

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10633


Walter Bright bugzi...@digitalmars.com changed:

   What|Removed |Added

 CC||bugzi...@digitalmars.com


--- Comment #1 from Walter Bright bugzi...@digitalmars.com 2013-07-15 
02:14:32 PDT ---
https://github.com/D-Programming-Language/dmd/pull/2347

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


[Issue 10633] Win64: wrong codegen with %=

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10633


Walter Bright bugzi...@digitalmars.com changed:

   What|Removed |Added

   Severity|normal  |major


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


[Issue 10645] New: Wrong codegen for shared struct with constructor and pass to atomicLoad

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10645

   Summary: Wrong codegen for shared struct with constructor and
pass to atomicLoad
   Product: D
   Version: D2
  Platform: x86_64
OS/Version: Linux
Status: NEW
  Severity: critical
  Priority: P2
 Component: DMD
AssignedTo: nob...@puremagic.com
ReportedBy: jfanati...@gmx.at


--- Comment #0 from jfanati...@gmx.at 2013-07-15 03:02:10 PDT ---
The following simple code:

--- 
cat  app2.d  EOF
import core.atomic;
import std.stdio;

struct Test {
this(long v) {
val = v;
}
long val;
}
void main() {
shared(Test) test = Test(7);
auto buf = atomicLoad(test);
writefln(buf: %s, orig: %s, buf, cast(Test)test);
}
EOF

---

produces the following output:

  buf: Test(0), orig: Test(7)

instead of the expected:

  buf: Test(7), orig: Test(7)


Assembly with objdump -d -g -C -S -l app2.o (full output appended):

void main() {
   0:55   push   %rbp
   1:48 8b ec mov%rsp,%rbp
   4:48 83 ec 10  sub$0x10,%rsp
/home/robert/projects/phobosx/source/app2.d:11
shared(Test) test = Test(7);
   8:48 8d 45 f0  lea-0x10(%rbp),%rax-0x10 is
right
   c:48 31 c9 xor%rcx,%rcx
   f:48 89 08 mov%rcx,(%rax)
  12:48 be 07 00 00 00 00 movabs $0x7,%rsi
  19:00 00 00 
  1c:48 89 c7 mov%rax,%rdiused here
correctly
  1f:e8 00 00 00 00   callq  24 _Dmain+0x24
  24:48 8d 75 f0  lea-0x10(%rbp),%rsi
/home/robert/projects/phobosx/source/app2.d:12
auto buf = atomicLoad(test);
  28:48 8d 7d f8  lea-0x8(%rbp),%rdi now -0x8, why?
  2c:e8 00 00 00 00   callq  31 _Dmain+0x31


It seems that the wrong address gets passed to atomicLoad. If you remove the
constructor of Test the right address (-0x10) is used. Various transformation
of this program all have the same wrong output: You can make test global, put
it in a union together with a plain long, create a non shared temporary before
assigning to the shared variable, use casts, ... The only thing that helps is
removing the constructor.

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


[Issue 10645] Wrong codegen for shared struct with constructor and pass to atomicLoad

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10645



--- Comment #1 from jfanati...@gmx.at 2013-07-15 03:10:02 PDT ---
Created an attachment (id=1233)
Full assembly dump

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


[Issue 10570] Example of `how` function for AutoImplement should work for non-abstract class

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10570



--- Comment #1 from github-bugzi...@puremagic.com 2013-07-15 05:05:01 PDT ---
Commits pushed to master at https://github.com/D-Programming-Language/phobos

https://github.com/D-Programming-Language/phobos/commit/bb50a33f1b27d94b7558661df1719d6e72afecda
Fixes Issue 10570

https://github.com/D-Programming-Language/phobos/commit/3095e8904a46a849a62ec03ea48f85525c7fe95a
Merge pull request #1401 from tom-tan/fix_generateLogger

Fix Issue 10570 - Example of `how` function for AutoImplement should work for
non-abstract class

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


[Issue 10570] Example of `how` function for AutoImplement should work for non-abstract class

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10570


Kenji Hara k.hara...@gmail.com changed:

   What|Removed |Added

   Keywords||pull
 Status|NEW |RESOLVED
 Resolution||FIXED


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


[Issue 10474] When takeExactly returns a new range type, it fails to propagate all relevant attributes

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10474



--- Comment #2 from github-bugzi...@puremagic.com 2013-07-15 05:05:29 PDT ---
Commits pushed to master at https://github.com/D-Programming-Language/phobos

https://github.com/D-Programming-Language/phobos/commit/32c3998ebda05bfed210f31d8ee70c845f014852
Fix for issue# 10474.

https://github.com/D-Programming-Language/phobos/commit/9b78a6f5e70935f6f709cea67379f8e34f6c3957
Merge pull request #1377 from jmdavis/10474

Fix for issue# 10474 -  takeExactly fails to propagate all relevant attributes

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


[Issue 10474] When takeExactly returns a new range type, it fails to propagate all relevant attributes

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10474


Kenji Hara k.hara...@gmail.com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
Version|unspecified |D2
 Resolution||FIXED


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


[Issue 10646] New: [ICE] when casting dynamic array/static array to class reference

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10646

   Summary: [ICE] when casting dynamic array/static array to class
reference
   Product: D
   Version: D2
  Platform: All
OS/Version: All
Status: NEW
  Severity: normal
  Priority: P2
 Component: DMD
AssignedTo: nob...@puremagic.com
ReportedBy: henn...@still-hidden.de


--- Comment #0 from Henning Pohl henn...@still-hidden.de 2013-07-15 06:31:45 
PDT ---
void main() {
class C { }

C[] csd;
C[2] css;
auto c1 = cast(C)csd;
auto c2 = cast(C)css;
}

---
test.d(6): Error: e2ir: cannot cast csd of type C[] to type test.main.C
test.d(7): Error: e2ir: cannot cast css of type C[2LU] to type test.main.C
---

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


[Issue 10646] [ICE] when casting dynamic array/static array to class reference

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10646


Henning Pohl henn...@still-hidden.de changed:

   What|Removed |Added

   Keywords||ice, pull


--- Comment #1 from Henning Pohl henn...@still-hidden.de 2013-07-15 06:36:32 
PDT ---
https://github.com/D-Programming-Language/dmd/pull/2348

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


[Issue 10647] New: AutoImplement should implement overridden member functions with 'override' attributes

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10647

   Summary: AutoImplement should implement overridden member
functions with 'override' attributes
   Product: D
   Version: D2
  Platform: All
OS/Version: All
Status: NEW
  Severity: normal
  Priority: P2
 Component: Phobos
AssignedTo: nob...@puremagic.com
ReportedBy: tta...@gmail.com


--- Comment #0 from Tomoya Tanjo tta...@gmail.com 2013-07-15 07:05:36 PDT ---
The following code should be compiled with no error messages but it does not.

---
// It is like BlackHole but it also overrides non-virtual functions
string generateDoNothing(C, alias fun)() @property
{
import std.traits;
string stmt;

static if (is(ReturnType!fun == void))
stmt ~= ;
else
{
string returnType = ReturnType!fun.stringof;
stmt ~= return ~returnType~.init;;
}
return stmt;
}

// A class to be overridden
class Foo{
void bar(int a) { }
}

// Do nothing template
template DoNothing(Base)
{
import std.typecons;
alias DoNothing = AutoImplement!(Base, generateDoNothing, isAlwaysTrue);
}

template isAlwaysTrue(alias fun)
{
enum isAlwaysTrue = true;
}

void main()
{
auto foo = new DoNothing!Foo();
foo.bar(13);
}
---

In dmd v2.064-devel-390a934 on Linux 64bit, it is compiled with the message
Deprecation: overriding base class function without using override attribute
is deprecated.
The reason is that current AutoImplement implements overridden member functions
with 'override' attritubes only for the abstract functions.
It is the reason why WhiteHole and BlackHole work without depcerated messages.
They only override abstract functions.

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


[Issue 10648] New: std.traits.isMutable is true for struct defined immutable

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10648

   Summary: std.traits.isMutable is true for struct defined
immutable
   Product: D
   Version: D2
  Platform: x86
OS/Version: Windows
Status: NEW
  Severity: normal
  Priority: P2
 Component: Phobos
AssignedTo: nob...@puremagic.com
ReportedBy: bearophile_h...@eml.cc


--- Comment #0 from bearophile_h...@eml.cc 2013-07-15 10:13:33 PDT ---
With dmd 2.064alpha this code runs with no assert errors:


import std.traits: isMutable;
immutable struct Foo {}
void main () {
static assert(isMutable!Foo);
}



Issue found by JS:
http://forum.dlang.org/thread/xjpfwfydzxxwqisvq...@forum.dlang.org

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


[Issue 10649] New: immutable/const aggregate definitions not consistent

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10649

   Summary: immutable/const aggregate definitions not consistent
   Product: D
   Version: D2
  Platform: All
OS/Version: All
Status: NEW
  Severity: normal
  Priority: P2
 Component: DMD
AssignedTo: nob...@puremagic.com
ReportedBy: pub...@dicebot.lv


--- Comment #0 from Dicebot pub...@dicebot.lv 2013-07-15 12:07:17 PDT ---
immutable struct A
{
struct B
{
int x;
}

int x;
static int y;
}

void main()
{
A.y = 42; // works
A a;
// a.x = 42; // fails
A.B b;
b.x = 42; // works
}

-

Applying const/immutable qualifier to aggregate definition propagates it only
to fields and methods of struct/class. static fields and nested definitions are
left mutable which is extremely confusing and inconsistent with usual
transitivity.

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


[Issue 10357] std.typecons.Nullable!(SysTime).Nullable.__ctor!() error instantiating

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10357


Jesse Phillips jesse.k.phillip...@gmail.com changed:

   What|Removed |Added

 CC||jesse.k.phillip...@gmail.co
   ||m


--- Comment #1 from Jesse Phillips jesse.k.phillip...@gmail.com 2013-07-15 
13:13:48 PDT ---
(In reply to comment #0)
 With D 2.063, the following code does no longer compile:
 
 import std.datetime;
 import std.typecons;
 
 unittest
 {
 Nullable!SysTime time = SysTime(0);
 }

A work around is:

unittest {
Nullable!SysTime time;
time = SysTime(0);
}

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


[Issue 10593] array's reserve/capacity go haywire if length has been changed prior

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10593


monarchdo...@gmail.com changed:

   What|Removed |Added

   Platform|x86 |All
 OS/Version|Windows |All
   Severity|critical|blocker


--- Comment #2 from monarchdo...@gmail.com 2013-07-15 13:40:35 PDT ---
I'm marking this as blocker.

The fact that a reserve could fail, while still doing something, is highly
problematic.

I also believe this is the issue creating the failures here:
https://github.com/D-Programming-Language/phobos/pull/1413

Will provide more information as I can.

Also: Confirmed on all platforms.

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


[Issue 9607] std.random.randomShuffle and partialShuffle don't work with Xorshift

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=9607



--- Comment #3 from github-bugzi...@puremagic.com 2013-07-15 15:16:10 PDT ---
Commits pushed to master at https://github.com/D-Programming-Language/phobos

https://github.com/D-Programming-Language/phobos/commit/e86bc65639036d240d5ec6ce0254ccebee097943
Fix Issue 9607 - std.random.randomShuffle() and partialShuffle()
don't work with Xorshift.

This is an instance of Issue 2803, a clash between a template
parameter and a default argument.  I've used the workaround
proposed in that issue thread:
http://d.puremagic.com/issues/show_bug.cgi?id=2803#c1

Tests have been included to ensure that these functions work
with all possible RNG types.

https://github.com/D-Programming-Language/phobos/commit/443b54e30b4b67b8968ecde51dcae66c855c135b
Merge pull request #1362 from WebDrake/randomshuffle

Fix Issue 9607 - std.random.randomShuffle() and partialShuffle() don't work
with Xorshift.

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


[Issue 10394] opBinaryRight!in and tuple

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10394



--- Comment #3 from Justin Whear jus...@economicmodeling.com 2013-07-15 
15:45:23 PDT ---
An update on this issue: we have worked around this by switching away from in
to a method-based approach, so this is no longer blocking for the reporter.  I
think this issue remains valid until it's decided whether the in operator (or
operators in general) will allow a tuple on the left hand side.  Here's a
simplified example that matches with our use case:
-
struct Graph(T, Address...)
{
struct Node
{
Address address;
T payload;
}

   ...

   Node* opBinaryRight(string op)(Address address) if (op == in)
   {
   ...
   }
}

void main()
{
Graph!(double, int, string) graph;
auto node = ...procure a node from somwhere...

// node.address is preferred to tuple(node.address)
if (auto inGraph = node.address in graph)
{
...
}
}
-

As I said, we have worked around this because it's not unreasonable for binary
operators to only allow one value on each side, but it was also nice to have
this kind of syntax in 2.062 and previous.

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


[Issue 10434] Don't use Random as template parameter name in std.random (or anywhere else)

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10434


hst...@quickfur.ath.cx changed:

   What|Removed |Added

 CC||hst...@quickfur.ath.cx


--- Comment #2 from hst...@quickfur.ath.cx 2013-07-15 16:16:22 PDT ---
+1 for RandGen, self-documenting and doesn't clash with existing symbol. Rng is
a bit obscure for those not in the know.

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


[Issue 9607] std.random.randomShuffle and partialShuffle don't work with Xorshift

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=9607


Andrej Mitrovic andrej.mitrov...@gmail.com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||andrej.mitrov...@gmail.com
 Resolution||FIXED


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


[Issue 10642] Win64: wrong codegen comparing different sized integer arguments

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10642


Walter Bright bugzi...@digitalmars.com changed:

   What|Removed |Added

 CC||bugzi...@digitalmars.com


--- Comment #2 from Walter Bright bugzi...@digitalmars.com 2013-07-15 
16:55:23 PDT ---
 compile with dmd -O -m64 test.d produces

Need to add -unittest

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


[Issue 10650] New: std.bitmanip.FixedBitArray

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10650

   Summary: std.bitmanip.FixedBitArray
   Product: D
   Version: D2
  Platform: All
OS/Version: All
Status: NEW
  Severity: enhancement
  Priority: P2
 Component: Phobos
AssignedTo: nob...@puremagic.com
ReportedBy: bearophile_h...@eml.cc


--- Comment #0 from bearophile_h...@eml.cc 2013-07-15 17:00:54 PDT ---
This is a struct with no defined constructor that uses a bit array of
statically known size:


import std.bitmanip: BitArray;
struct Foo {
enum nBits = 1_024;
size_t[nBits / size_t.sizeof] buffer;
BitArray bitSet;
bool isInitialized = false;

void bar() /*pure nothrow*/ {
if (!isInitialized) {
 bitSet.init(buffer, nBits);
 isInitialized = true;
 }

// ...
}
}
void main() {}



A statically known size is useful to reduce pressure a bit on the GC, to
increase cache locality, etc. So I suggest to introduce in std.bitmanip a
simple FixedBitArray based on BitArray that offers a simpler usage for
statically known sizes of bit arrays:


struct FixedBitArray(size_t nBits) {
private size_t[nBits / size_t.sizeof + (nBits % size_t.sizeof) ? 1 : 0]
buffer;
...
}


import std.bitmanip: FixedBitArray;
struct Foo {
FixedBitArray!(1_024) bitSet;

void bar() pure nothrow {
// ...
}
}
void main() {}


An alternative name is BoundedBitArray as in the Ada 2012 bounded
collections.

An alternative is to modify BitArray to allow both usages nicely.

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


[Issue 10642] Win64: wrong codegen comparing different sized integer arguments

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10642


Walter Bright bugzi...@digitalmars.com changed:

   What|Removed |Added

 OS/Version|Windows |All
   Severity|normal  |major


--- Comment #3 from Walter Bright bugzi...@digitalmars.com 2013-07-15 
17:48:51 PDT ---
https://github.com/D-Programming-Language/dmd/pull/2349

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


[Issue 10605] Lambda grammar is not sufficient

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10605



--- Comment #2 from github-bugzi...@puremagic.com 2013-07-15 17:59:55 PDT ---
Commits pushed to master at https://github.com/D-Programming-Language/dlang.org

https://github.com/D-Programming-Language/dlang.org/commit/f7e72cc9885eaab905810ef5afc448c5bf197292
fix Issue 10605 - Lambda grammar is not sufficient

Improve Lambda grammar and describe rewrite rule

https://github.com/D-Programming-Language/dlang.org/commit/c73a1f5cdd283a9bc741d8883defee9901c1234d
Merge pull request #351 from 9rnsr/fix_lambda

Issue 10605 - Lambda grammar is not sufficient

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


[Issue 10648] std.traits.isMutable is true for struct defined immutable

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10648


Kenji Hara k.hara...@gmail.com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||INVALID


--- Comment #1 from Kenji Hara k.hara...@gmail.com 2013-07-15 18:07:35 PDT ---
(In reply to comment #0)
 With dmd 2.064alpha this code runs with no assert errors:
 
 
 import std.traits: isMutable;
 immutable struct Foo {}
 void main () {
 static assert(isMutable!Foo);
 }
 
 
 
 Issue found by JS:
 http://forum.dlang.org/thread/xjpfwfydzxxwqisvq...@forum.dlang.org

It is not an issue. Because:

1. Qualified struct declaration and its behavior is properly documented.
 http://dlang.org/struct#ConstStruct

2. The struct name `Foo` always represent 'mutable type Foo'. And, isMutable
tests whether the type qualifier is mutable or not.

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


[Issue 10605] Lambda grammar is not sufficient

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10605


Kenji Hara k.hara...@gmail.com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||FIXED


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


[Issue 10646] No front-end error for invalid casting dynamic array/static array to class reference

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10646


Kenji Hara k.hara...@gmail.com changed:

   What|Removed |Added

   Keywords|ice |
Summary|[ICE] when casting dynamic  |No front-end error for
   |array/static array to class |invalid casting dynamic
   |reference   |array/static array to class
   ||reference


--- Comment #2 from Kenji Hara k.hara...@gmail.com 2013-07-15 18:54:52 PDT ---
(In reply to comment #0)
 void main() {
 class C { }
 
 C[] csd;
 C[2] css;
 auto c1 = cast(C)csd;
 auto c2 = cast(C)css;
 }
 
 ---
 test.d(6): Error: e2ir: cannot cast csd of type C[] to type test.main.C
 test.d(7): Error: e2ir: cannot cast css of type C[2LU] to type test.main.C
 ---

I think there's no Internal Compiler Error. These are proper errors but just
come from glue layer.

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


[Issue 10651] New: Throwing non-Throwable object causes ICE

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10651

   Summary: Throwing non-Throwable object causes ICE
   Product: D
   Version: D2
  Platform: All
OS/Version: All
Status: NEW
  Keywords: ice
  Severity: normal
  Priority: P2
 Component: DMD
AssignedTo: nob...@puremagic.com
ReportedBy: k.hara...@gmail.com


--- Comment #0 from Kenji Hara k.hara...@gmail.com 2013-07-15 19:08:19 PDT ---
Code:
void main()
{
alias T = int;
throw new T();  // ICE
}

Output:
test.d(4): Error: can only throw class objects derived from Throwable, not type
int*
assert statement.c(4894) cd

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


[Issue 10651] Throwing non-Throwable object causes ICE

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10651


Kenji Hara k.hara...@gmail.com changed:

   What|Removed |Added

   Keywords||pull


--- Comment #1 from Kenji Hara k.hara...@gmail.com 2013-07-15 19:14:50 PDT ---
https://github.com/D-Programming-Language/dmd/pull/2350

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


[Issue 10647] AutoImplement should implement overridden member functions with 'override' attributes

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10647


Kenji Hara k.hara...@gmail.com changed:

   What|Removed |Added

   Keywords||pull, rejects-valid


--- Comment #1 from Kenji Hara k.hara...@gmail.com 2013-07-15 19:49:26 PDT ---
https://github.com/D-Programming-Language/phobos/pull/1416

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


[Issue 10651] Throwing non-Throwable object causes ICE

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10651



--- Comment #2 from github-bugzi...@puremagic.com 2013-07-15 20:42:56 PDT ---
Commits pushed to master at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/4a3faa1be01d9518aa5286f686f8927689bc4d7d
fix Issue 10651 - Throwing non-Throwable object causes ICE

https://github.com/D-Programming-Language/dmd/commit/0627f87bbd34db8493d21c8d88c32fef49065980
Merge pull request #2350 from 9rnsr/fix10651

Issue 10651 - Throwing non-Throwable object causes ICE

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


[Issue 10651] Throwing non-Throwable object causes ICE

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=10651


yebblies yebbl...@gmail.com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||yebbl...@gmail.com
 Resolution||FIXED


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


[Issue 8318] Cannot override a method with inferred return type

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=8318


Kenji Hara k.hara...@gmail.com changed:

   What|Removed |Added

 CC||yazan.dab...@gmail.com


--- Comment #3 from Kenji Hara k.hara...@gmail.com 2013-07-15 22:05:18 PDT ---
*** Issue 9784 has been marked as a duplicate of this issue. ***

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


[Issue 9784] Fail to use auto when implementing class interface methods

2013-07-15 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=9784


Kenji Hara k.hara...@gmail.com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution||DUPLICATE


--- Comment #2 from Kenji Hara k.hara...@gmail.com 2013-07-15 22:05:18 PDT ---
*** This issue has been marked as a duplicate of issue 8318 ***

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