[Issue 13024] [ICE](expression.c line 1172) with implicit supertype conversion of different enums in array literal

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13024

--- Comment #3 from github-bugzi...@puremagic.com ---
Commits pushed to master at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/aec7dff579c3873894c309ccb90e190d20289b0a
fix Issue 13024 - [ICE](expression.c line 1172) with implicit supertype
conversion of different enums in array literal

https://github.com/D-Programming-Language/dmd/commit/e0ca2d2005574aa90322deb6eb130860a6124e6f
Merge pull request #3733 from 9rnsr/fix13024

[REG2.066a] Issue 13024 - [ICE](expression.c line 1172) with implicit supertype
conversion of different enums in array literal

--


[Issue 13024] Refused implicit supertype conversion of different enums in array literal

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13024

bearophile_h...@eml.cc changed:

   What|Removed |Added

   Keywords|ice, pull   |rejects-valid
 Status|RESOLVED|REOPENED
 Resolution|FIXED   |---
Summary|[ICE](expression.c line |Refused implicit supertype
   |1172) with implicit |conversion of different
   |supertype conversion of |enums in array literal
   |different enums in array|
   |literal |

--- Comment #4 from bearophile_h...@eml.cc ---
Reopened, because as explained both here and in the pull request, the pull
request fixes only part of the bug. Now this code:


enum A { a }
enum B { b }
struct T { A x; B y; }
void main() {
T t;
auto r1 = [int(t.x), int(t.y)]; // OK
auto r2 = [t.tupleof]; // error
}


Gives with dmd 2.066beta2:

test.d(7,16): Error: cannot implicitly convert expression (t.x) of type A to B

Changed the issue name a little because now it's not an ICE, it's a
rejects-valid.

--


[Issue 13092] New: std.algorithm.cartesianProduct of Nullable Tuple of strings array too

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13092

  Issue ID: 13092
   Summary: std.algorithm.cartesianProduct of Nullable Tuple of
strings array too
   Product: D
   Version: D2
  Hardware: x86
OS: Windows
Status: NEW
  Keywords: rejects-valid
  Severity: normal
  Priority: P1
 Component: Phobos
  Assignee: nob...@puremagic.com
  Reporter: bearophile_h...@eml.cc

I think all this program should compile:


void main() {
import std.typecons: Tuple, Nullable;
import std.algorithm: cartesianProduct;
string[] a;
const Nullable!(Tuple!(string[])) b;
const string[] c = b.get[0]; // OK
foreach (ab; cartesianProduct(a, c)) {} // OK
foreach (ab; cartesianProduct(a, b[0])) {} // fails
foreach (ab; cartesianProduct(a, b.get[0])) {} // fails
}


With dmd 2.066beta2 it gives:

...\dmd2\src\phobos\std\algorithm.d(12783,10): Error: static assert 
cartesianProduct involving finite ranges must have at least one finite forward
range
test.d(8,34):instantiated from here: cartesianProduct!(string[],
const(immutable(char)[][]))

--


[Issue 12448] in argument for std.string.toStringz

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12448

bearophile_h...@eml.cc changed:

   What|Removed |Added

 Status|REOPENED|RESOLVED
 Resolution|--- |FIXED

--- Comment #9 from bearophile_h...@eml.cc ---
(In reply to Robert Schadek from comment #8)
 I don't really follow.
 
 If this issue is none existing anymore, why should this stay open?

The original problem is solved, but I was thinking about keeping this issue
open for a different purpose: to ask the signature of toStringz to become
toStringz(in string s) anyway. But this is not so important, so I close this
issue again.

--


[Issue 13093] New: D ABI change for guaranteed efficient return of fixed size array

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13093

  Issue ID: 13093
   Summary: D ABI change for guaranteed efficient return of fixed
size array
   Product: D
   Version: D2
  Hardware: All
OS: All
Status: NEW
  Severity: enhancement
  Priority: P1
 Component: DMD
  Assignee: nob...@puremagic.com
  Reporter: bearophile_h...@eml.cc

I suggest to change the D ABI to make code like this avoid an array copy in
100% of the cases (without inlining, and regardless the optimization levels,
and in all D compilers):


ubyte[1] foo() nothrow @safe {
typeof(return) data;
// Some code here.
return data;
}
void main() nothrow {
immutable data = foo();
}


That means that code is equivalent to (note the need for the explicit cast):

void foo(ref ubyte[1] __data) nothrow @safe {
__data[] = 0;
// Some code here.
}
void main() nothrow {
ubyte[1] __data = void;
foo(__data);
immutable data = cast(immutable ubyte[1])__data;
}


If the returned fixed-size array is very small (like one or two CPU words, or
perhaps even three), the new ABI can specify it's returned by value in
registers.

In my @nogc code I'd like to use fixed-size arrays, so it's nice to be sure
they are _always_ returned efficiently, and at the same time keep a nice syntax
that allows me to tag the result as immutable (and more DRY code that avoids to
repeat ubyte[1] more than once as it happens in the second program).


Dmitry Olshansky has commented:
http://forum.dlang.org/thread/xvtnfpsqlzxptjjfh...@forum.dlang.org

 IMO this is a good idea and it pretty much NRVO/RVO for structs extended 
 to fixed-size arrays (which more or less a special kind of struct). 
 Since C/C++ do not have fixed-size arrays passed by value I see no 
 damage to ABI compatibility.

--


[Issue 13024] Refused implicit supertype conversion of different enums in array literal

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13024

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

   What|Removed |Added

   Severity|regression  |normal

--- Comment #5 from Kenji Hara k.hara...@gmail.com ---
(In reply to bearophile_hugs from comment #4)
 Reopened, because as explained both here and in the pull request, the pull
 request fixes only part of the bug. Now this code:

ICE issue was a regression, but failing common type calculation is not
regression. So change 'importance' to normal.

(In next time, please file a new issue instead of reopening)

--


[Issue 13006] Allow inout return type without inout parameters

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13006

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

   What|Removed |Added

   Keywords||pull

--- Comment #1 from Kenji Hara k.hara...@gmail.com ---
https://github.com/D-Programming-Language/dmd/pull/3740

--


[Issue 13024] [ICE](expression.c line 1172) with implicit supertype conversion of different enums in array literal

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13024

bearophile_h...@eml.cc changed:

   What|Removed |Added

   Keywords|rejects-valid   |ice, pull
 Status|REOPENED|RESOLVED
 Resolution|--- |FIXED
Summary|Refused implicit supertype  |[ICE](expression.c line
   |conversion of different |1172) with implicit
   |enums in array literal  |supertype conversion of
   ||different enums in array
   ||literal
   Severity|normal  |regression

--- Comment #6 from bearophile_h...@eml.cc ---
(In reply to Kenji Hara from comment #5)

 (In next time, please file a new issue instead of reopening)

Sorry, I close this now, and I'll reopen another one.

--


[Issue 13094] New: Refused implicit supertype conversion of different enums in array literal

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13094

  Issue ID: 13094
   Summary: Refused implicit supertype conversion of different
enums in array literal
   Product: D
   Version: D2
  Hardware: x86
OS: Windows
Status: NEW
  Keywords: rejects-valid
  Severity: normal
  Priority: P1
 Component: DMD
  Assignee: nob...@puremagic.com
  Reporter: bearophile_h...@eml.cc

enum A { a }
enum B { b }
struct T { A x; B y; }
void main() {
T t;
auto r1 = [int(t.x), int(t.y)]; // OK
auto r2 = [t.tupleof]; // error
}


Gives with dmd 2.066beta2:

test.d(7,16): Error: cannot implicitly convert expression (t.x) of type A to B

--


[Issue 13095] New: Someteims `struct` destructor is called if constructor throws

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13095

  Issue ID: 13095
   Summary: Someteims `struct` destructor is called if constructor
throws
   Product: D
   Version: D2
  Hardware: All
OS: All
Status: NEW
  Keywords: wrong-code
  Severity: major
  Priority: P1
 Component: DMD
  Assignee: nob...@puremagic.com
  Reporter: verylonglogin@gmail.com

This code should run fine:
---
import std.stdio;

bool b = false;

struct S
{
this(int) { throw new Exception(); }

~this() { b = true; }
}

void main()
{
try S(0); catch(Exception) { }
assert(!b); // fails
}
---

Also if a `Throwable` is thrown in destructor it is called recursively:
---
import std.stdio;

struct S
{
this(int)
{
throw new Exception();
}

~this()
{
int p;
asm { mov p, ESP; }
writefln(~this, ESP: 0x%X, p);
throw new Error(); // calls `~this`
}
}

void main()
{
try
S(0);
catch(Exception)
writeln(catch Exception);
writeln(end main);
}
---
prints '~this, ESP: 0x...' until stack overflows
---

This is a major issue breaking RAII code.

--


[Issue 13024] [ICE](expression.c line 1172) with implicit supertype conversion of different enums in array literal

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13024

--- Comment #7 from Kenji Hara k.hara...@gmail.com ---
(In reply to bearophile_hugs from comment #6)
 (In reply to Kenji Hara from comment #5)
 
  (In next time, please file a new issue instead of reopening)
 
 Sorry, I close this now, and I'll reopen another one.

Thank you.

--


[Issue 704] `class` destructor is called even if constructor throws

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=704

Denis Shelomovskij verylonglogin@gmail.com changed:

   What|Removed |Added

 CC||verylonglogin@gmail.com
   Hardware|x86 |All
Summary|destructors are called even |`class` destructor is
   |if the constructor throws   |called even if constructor
   |an exception|throws
 OS|Linux   |All

--- Comment #8 from Denis Shelomovskij verylonglogin@gmail.com ---
---(In reply to Andrei Alexandrescu from comment #7)
 On the other hand we don't throw if a struct's ctor throws. So this is an
 inconsistency.I think it's fair in D to consider a throwing constructor as
 abandoning all construction of the object.

Also `scope` classes behaves like structs:
---
class C
{
this() { throw new Exception(); }

~this() { assert(0); } // never called
}

void main()
{
try scope c = new C(); catch(Exception) { }
}
---

As for structs, we also have Issue 13095.

--


[Issue 13095] Someteims `struct` destructor is called if constructor throws

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13095

--- Comment #1 from Denis Shelomovskij verylonglogin@gmail.com ---
Note:
Replacing `S(0)` with `S s = S(0)` or `f(S(0))` detriggers the issue.

--


[Issue 13055] @nogc std.string.sformat

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13055

--- Comment #1 from bearophile_h...@eml.cc ---
One of my intended usages for this function is to generate messages for
exceptions in @nogc code. Chris Cain comments:

 It's just stack-allocated this way isn't possible since the 
 exception can be thrown into a scope above your stack allocated 
 chars.

--


[Issue 13093] D ABI change for guaranteed efficient return of fixed size array

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13093

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

   What|Removed |Added

   Keywords||pull
  Component|DMD |websites
   Severity|enhancement |normal

--- Comment #1 from Kenji Hara k.hara...@gmail.com ---
It's already supported, but not explicitly described in ABI page.

From http://dlang.org/abi

Return Value
...
* 1, 2 and 4 byte structs are returned in EAX.
* 8 byte structs are returned in EDX,EAX, where EDX gets the most significant
half.
* For other struct sizes, the return value is stored through a hidden pointer
passed as an argument to the function.
...

Normally static arrays are treated as the same size structs, so ubyte[1000] is
always returned through hidden pointer.

https://github.com/D-Programming-Language/dlang.org/pull/611

--


[Issue 13093] D ABI change for guaranteed efficient return of fixed size array

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13093

--- Comment #2 from Kenji Hara k.hara...@gmail.com ---
You can test it by the code.

void* p;
ubyte[1] foo() nothrow {
typeof(return) data;
p = data;
return data;
}
void main() nothrow {
immutable data = foo();
assert(p == data);
}

--


[Issue 8269] The 'with statement' does not observe temporary object lifetime

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=8269

Denis Shelomovskij verylonglogin@gmail.com changed:

   What|Removed |Added

   Keywords||wrong-code
 CC||verylonglogin@gmail.com
   Severity|normal  |major

--- Comment #5 from Denis Shelomovskij verylonglogin@gmail.com ---
Smaller testcase:
---
struct S
{
bool alive = true;

~this() { alive = false; }
}

void main()
{
with(S()) // -- `S` is created and destructed here
assert(alive); // fails
}
---

This is a major issue as it breaks RAII.

--


[Issue 13096] New: Imported private identifiers conflict with public ones.

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13096

  Issue ID: 13096
   Summary: Imported private identifiers conflict with public
ones.
   Product: D
   Version: D2
  Hardware: All
OS: All
Status: NEW
  Severity: normal
  Priority: P1
 Component: DMD
  Assignee: nob...@puremagic.com
  Reporter: yuriy.gluk...@gmail.com

// m1.d
private struct S { }

// m2.d
struct S { }

// main.d
import m1;
import m2;
void main()
{
S s;
}

Compiler error:
./main.d(5): Error: m1.S at m1.d(2) conflicts with m2.S at m2.d(2)
./main.d(5): Error: module test struct m1.S is private

--


[Issue 13097] New: linker error: undefined reference to symbol '_end', bisected to druntime 09ea3d

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13097

  Issue ID: 13097
   Summary: linker error: undefined reference to symbol '_end',
bisected to druntime 09ea3d
   Product: D
   Version: D2
  Hardware: x86_64
OS: Linux
Status: NEW
  Severity: normal
  Priority: P1
 Component: druntime
  Assignee: nob...@puremagic.com
  Reporter: zor...@gmail.com

New installation of Arch, dmd/druntime/phobos from git (v2.066-devel-e0ca2d2).

Building dub (git 8c8934) fails with a linker error. Other stuff (Digger, small
test snippets) seems to build fine.

  gcc bin/dub.o -o bin/dub -g -m64 -l:libphobos2.a -lcurl
-L/mnt/main/src/d/dlang-workspace -Xlinker --no-warn-search-mismatch -Xlinker
--export-dynamic -l:libphobos2.a -lpthread -lm -lrt
  /usr/bin/ld:
/mnt/main/src/d/dlang-workspace/libphobos2.a(sections_linux_553_883.o):
undefined reference to symbol '_end'
  /usr/lib/libssl.so.1.0.0: error adding symbols: DSO missing from command line
  collect2: error: ld returned 1 exit status

pacman reports libssl to be version 1.0.1.h-1.

Digger bisect result:

  commit 09ea3d684b6a815d2b9013b6cf2d4e30a4c70301
  Merge: 591b8d4 82c9b2d
  Author: Walter Bright wal...@walterbright.com
  Date:   Mon May 26 03:32:45 2014 -0700

  Merge pull request #791 from MartinNowak/fix11543

  fix for Issue 11543 - multiple definition of std.regex with shared
library

--


[Issue 13072] Cherry-picks for v2.066.0-b3

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13072

Dragos Carp dragosc...@gmail.com changed:

   What|Removed |Added

 CC||dragosc...@gmail.com

--- Comment #2 from Dragos Carp dragosc...@gmail.com ---
https://github.com/D-Programming-Language/dmd/pull/3735

https://github.com/D-Programming-Language/dmd/pull/3730

--


[Issue 13072] Cherry-picks for v2.066.0-b3

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13072

--- Comment #3 from Dragos Carp dragosc...@gmail.com ---
Please take back pull 3735. Walter is still working on it...

See: https://github.com/D-Programming-Language/dmd/pull/3739

--


[Issue 13096] Imported private identifiers conflict with public ones.

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13096

--- Comment #1 from Yuriy yuriy.gluk...@gmail.com ---
Proposed PR:
https://github.com/D-Programming-Language/dmd/pull/3743

--


[Issue 13072] Cherry-picks for v2.066.0-b3

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13072

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

   What|Removed |Added

   Keywords||pull

--- Comment #4 from Kenji Hara k.hara...@gmail.com ---
Opened pull requests for 2.066 branches in each repos:

https://github.com/D-Programming-Language/dmd/pull/3742
https://github.com/D-Programming-Language/phobos/pull/2322

--


[Issue 13084] ModuleInfo.opApply delegate expects immutable parameter

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13084

--- Comment #3 from Kenji Hara k.hara...@gmail.com ---
(In reply to Jacob Carlborg from comment #2)
 I assumed that, but i still breaks code. What about the standard deprecation
 cycle?

Unfortunately, it's impossible. We cannot allow iterating both mutable and
immutable objects by ModuleInfo.opApply, because it will cause type system 
violation. We should change the opApply signature all at once.

And compiler already place all ModuleInfo in read-only section. So modifying
ModuleInfo will cause segfault in some platforms. It's more worse.

--


[Issue 13078] [dmd 2.066-b2] AA rehash failed with shared

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13078

--- Comment #2 from github-bugzi...@puremagic.com ---
Commits pushed to master at https://github.com/D-Programming-Language/druntime

https://github.com/D-Programming-Language/druntime/commit/f05177bb2daa83ddea507baed9628c4dedfd223d
fix Issue 13078 - [dmd 2.066-b2] AA rehash failed with shared

https://github.com/D-Programming-Language/druntime/commit/a13628a4534b07ee956b43c66ea311e50de94934
Merge pull request #877 from 9rnsr/fix13078

[REG2.066a] Issue 13078 - [dmd 2.066-b2] AA rehash failed with shared

--


[Issue 13078] [dmd 2.066-b2] AA rehash failed with shared

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13078

--- Comment #3 from github-bugzi...@puremagic.com ---
Commit pushed to 2.066 at https://github.com/D-Programming-Language/druntime

https://github.com/D-Programming-Language/druntime/commit/3d039ed4004840302bc6c0834f2dd2541785a351
Merge pull request #877 from 9rnsr/fix13078

[REG2.066a] Issue 13078 - [dmd 2.066-b2] AA rehash failed with shared

--


[Issue 13071] [ICE] dmd 2.066.0-b1 assertion in nogc.c:73

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13071

--- Comment #3 from github-bugzi...@puremagic.com ---
Commit pushed to 2.066 at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/10499414c5fa77d704e921a47a531abff15d2856
Merge pull request #3730 from 9rnsr/fix13071

[REG2.066a] Issue 13071 - [ICE] dmd 2.066.0-b1 assertion in nogc.c:73

--


[Issue 13087] Error: no property 'xyz' for type 'Vec!4'

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13087

--- Comment #4 from github-bugzi...@puremagic.com ---
Commit pushed to 2.066 at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/9695e29f4aced4d8f7e775902bdde8922b44b937
Merge pull request #3736 from 9rnsr/fix13087

[REG2.066a] Issue 13087 - Error: no property 'xyz' for type 'Vec!4'

--


[Issue 13024] [ICE](expression.c line 1172) with implicit supertype conversion of different enums in array literal

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13024

--- Comment #8 from github-bugzi...@puremagic.com ---
Commit pushed to 2.066 at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/8ca5956e10ed9637ae35911c0afae37faffd3c56
Merge pull request #3733 from 9rnsr/fix13024

[REG2.066a] Issue 13024 - [ICE](expression.c line 1172) with implicit supertype
conversion of different enums in array literal

--


[Issue 13081] ICE with alias this and opSlice

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13081

--- Comment #4 from github-bugzi...@puremagic.com ---
Commit pushed to 2.066 at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/e18332655fbe96ccd640d4f005e30b936d6f884b
Merge pull request #3732 from 9rnsr/fix13081

[REG2.066a] Issue 13081 - ICE with alias this and opSlice

--


[Issue 13074] Old opCmp requirement for AA keys should be detected

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13074

--- Comment #4 from github-bugzi...@puremagic.com ---
Commits pushed to 2.066 at https://github.com/D-Programming-Language/phobos

https://github.com/D-Programming-Language/phobos/commit/bc4d38f9aefc89a7568669fc3cb1070523f6813d
Merge pull request #2313 from 9rnsr/fix13074

Supplemental fix for issue 13074 - Revert Merge pull request #1827 from
WalterBright/add-opCmp

https://github.com/D-Programming-Language/phobos/commit/742889a2e514533edd83d9574ee1c721138f23f5
Merge pull request #2314 from 9rnsr/fix13074

Supplemental fix for issue 13074 - revert opEquals and add toHash in
std.typecons.Tuple

--


[Issue 13076] [dmd 2.066-b2] DList clearing of empty list

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13076

--- Comment #4 from github-bugzi...@puremagic.com ---
Commit pushed to 2.066 at https://github.com/D-Programming-Language/phobos

https://github.com/D-Programming-Language/phobos/commit/9102be68d560412719eddcc63c66c0272a83a8fa
Merge pull request #2315 from 9rnsr/fix13076

[REG2.066a] Issue 13076 - [dmd 2.066-b2] DList clearing of empty list

--


[Issue 13074] Old opCmp requirement for AA keys should be detected

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13074

github-bugzi...@puremagic.com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED

--


[Issue 13074] Old opCmp requirement for AA keys should be detected

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13074

--- Comment #5 from github-bugzi...@puremagic.com ---
Commits pushed to master at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/11a29600c94a599ea670c8ba1a134a6ea5bcf491
fix Issue 13074 - Old opCmp requirement for AA keys should be detected

https://github.com/D-Programming-Language/dmd/commit/8bee69a9262cbd6b47528f8f09e15b70e0a9a605
Merge pull request #3731 from 9rnsr/fix13074

Issue 13074 - Old opCmp requirement for AA keys should be detected

--


[Issue 13074] Old opCmp requirement for AA keys should be detected

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13074

--- Comment #6 from github-bugzi...@puremagic.com ---
Commit pushed to 2.066 at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/601d4786af647204779488844e50e6906ce43e0d
Merge pull request #3731 from 9rnsr/fix13074

Issue 13074 - Old opCmp requirement for AA keys should be detected

--


[Issue 13098] New: std.path.baseName no longer works with DirEntry

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13098

  Issue ID: 13098
   Summary: std.path.baseName no longer works with DirEntry
   Product: D
   Version: unspecified
  Hardware: All
OS: All
Status: NEW
  Severity: regression
  Priority: P1
 Component: Phobos
  Assignee: nob...@puremagic.com
  Reporter: c...@dawg.eu

This regression was introduced by templating baseName and enforcing
isSomeString for the argument. Previously baseName took a const(char)[]
argument which triggered the implicit conversion of DirEntry to string (via
alias name this).

--


[Issue 13098] std.path.baseName no longer works with DirEntry

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13098

--- Comment #1 from Martin Nowak c...@dawg.eu ---
Introduced by https://github.com/D-Programming-Language/phobos/pull/2169.
The regression applies to all of the following std.path methods.
baseName, extSeparatorPos, extension, isRooted, isAbsolute

The fix is to simply add a const(char)[] function as overload, which also saves
some template instantiation in user code.

--


[Issue 13056] [2.066.0-b1] Regression: Error: template std.path.baseName cannot deduce function from argument types !()(DirEntry)

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13056

Martin Nowak c...@dawg.eu changed:

   What|Removed |Added

 CC||c...@dawg.eu

--- Comment #6 from Martin Nowak c...@dawg.eu ---
*** Issue 13098 has been marked as a duplicate of this issue. ***

--


[Issue 13098] std.path.baseName no longer works with DirEntry

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13098

Martin Nowak c...@dawg.eu changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |DUPLICATE

--- Comment #2 from Martin Nowak c...@dawg.eu ---


*** This issue has been marked as a duplicate of issue 13056 ***

--


[Issue 13072] Cherry-picks for v2.066.0-b3

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13072

Jonathan Crapuchettes jcrapuchet...@gmail.com changed:

   What|Removed |Added

 CC||jcrapuchet...@gmail.com

--- Comment #5 from Jonathan Crapuchettes jcrapuchet...@gmail.com ---
https://github.com/D-Programming-Language/phobos/pull/2072

--


[Issue 13098] std.path functions no longer works with DirEntry

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13098

Martin Nowak c...@dawg.eu changed:

   What|Removed |Added

Summary|std.path.baseName no longer |std.path functions no
   |works with DirEntry |longer works with DirEntry

--


[Issue 13072] Cherry-picks for v2.066.0-b3

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13072

Andrew Edwards edwards...@gmail.com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |WONTFIX

--- Comment #6 from Andrew Edwards edwards...@gmail.com ---
Sorry Jonathon, you just missed it. v2.066.0-b3 has been building for about 20
minutes now.

--


[Issue 12556] Add persistent byLine

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12556

Justin Whear jus...@economicmodeling.com changed:

   What|Removed |Added

 CC||jus...@economicmodeling.com

--


[Issue 13098] std.path functions no longer works with DirEntry

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13098

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

   What|Removed |Added

   Keywords||pull, rejects-valid
 Status|RESOLVED|REOPENED
Version|unspecified |D2
 Resolution|DUPLICATE   |---

--- Comment #3 from Kenji Hara k.hara...@gmail.com ---
https://github.com/D-Programming-Language/phobos/pull/2324

--


[Issue 12643] @nogc std.range.dropOne

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12643

Justin Whear jus...@economicmodeling.com changed:

   What|Removed |Added

 CC||jus...@economicmodeling.com

--- Comment #1 from Justin Whear jus...@economicmodeling.com ---
The array literal will trip in this case.  This test code compiles with the
latest git head (v2.066-devel-8bee69a):

unittest
{
void ensureNoGC() @nogc
{
int[] a1;
auto a2 = a1.dropOne;
auto s1 = hello;
auto s2 = s1.dropOne;
}
}

--


[Issue 12643] @nogc std.range.dropOne

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12643

bearophile_h...@eml.cc changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED

--- Comment #2 from bearophile_h...@eml.cc ---
OK, closed.

--


[Issue 12781] process.d: Executable file not found is supposed to show executable name but fails

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12781

Justin Whear jus...@economicmodeling.com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||jus...@economicmodeling.com
 Resolution|--- |FIXED

--- Comment #1 from Justin Whear jus...@economicmodeling.com ---
Fixed in git head by commit 0812ecd1f6519028070eba0c9b4504bded48a7a5

--


[Issue 13099] New: @nogc std.range.stride

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13099

  Issue ID: 13099
   Summary: @nogc std.range.stride
   Product: D
   Version: D2
  Hardware: x86
OS: Windows
Status: NEW
  Severity: enhancement
  Priority: P1
 Component: Phobos
  Assignee: nob...@puremagic.com
  Reporter: bearophile_h...@eml.cc

void main() @nogc {
import std.range: stride;
int[] a;
a.stride(2);
}


dmd 2.066beta gives:

test.d(4,13): Error: @nogc function 'D main' cannot call non-@nogc function
'std.range.stride!(int[]).stride'


Currently std.range.stride is not @nogc just because of this enforce:


auto stride(Range)(Range r, size_t n) @nogc
if (isInputRange!(Unqual!Range))
{
import std.exception : enforce;

enforce(n  0, Stride cannot have step zero.);
...



The given code compiles if you replace the enforce with:


immutable static exc = new Exception(Stride cannot have step zero.);
if (n == 0)
throw exc;



But look at the comment by monarchdodra in Issue 12768 .

--


[Issue 13098] std.path functions no longer works with DirEntry

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13098

--- Comment #4 from github-bugzi...@puremagic.com ---
Commits pushed to master at https://github.com/D-Programming-Language/phobos

https://github.com/D-Programming-Language/phobos/commit/3a114c45fb89377413ae0cf33bc8c047c8875799
fix Issue 13098 - std.path functions no longer works with DirEntry

https://github.com/D-Programming-Language/phobos/commit/20d2e6cd4f386a0fba8599588ded68a99b0efa8b
Merge pull request #2324 from MartinNowak/fix13098

[REG2.066a] Issue 13098 - std.path functions no longer works with DirEntry

--


[Issue 13025] Tools repository does not build on Ubuntu

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13025

--- Comment #5 from Martin Nowak c...@dawg.eu ---
This happens when linking with libcurl, I can add -L--no-as-needed -L-lcurl to
any dmd app and it will trigger this issue.

--


[Issue 13025] Tools repository does not build on Ubuntu

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13025

--- Comment #6 from David Nadlinger c...@klickverbot.at ---
(In reply to Martin Nowak from comment #5)
 This happens when linking with libcurl, I can add -L--no-as-needed -L-lcurl
 to any dmd app and it will trigger this issue.

This sounds eerily similar to a problem I had with _end way back when:
http://stackoverflow.com/questions/13328144/end-symbol-disappears-when-linking-to-libcurl

Still unresolved, though.

--


[Issue 13025] Tools repository does not build on Ubuntu

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13025

--- Comment #7 from Martin Nowak c...@dawg.eu ---
(In reply to David Nadlinger from comment #6)
 This sounds eerily similar to a problem I had with _end way back when:
 http://stackoverflow.com/questions/13328144/end-symbol-disappears-when-
 linking-to-libcurl
 
 Still unresolved, though.

Oh, I remember this one, but we actually did resolve it back then.
https://github.com/D-Programming-Language/druntime/commit/760aba5256d91327e5b4e79d931bceee4c068cd6
Now the question is, why does linking with libcurl affect the linker provided
symbols.

--


[Issue 12815] Dummy file

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12815

Justin Whear jus...@economicmodeling.com changed:

   What|Removed |Added

 CC||jus...@economicmodeling.com

--


[Issue 12815] Dummy file

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12815

Justin Whear jus...@economicmodeling.com changed:

   What|Removed |Added

 Status|NEW |ASSIGNED

--- Comment #1 from Justin Whear jus...@economicmodeling.com ---
https://github.com/D-Programming-Language/phobos/pull/2325

--


[Issue 12815] Dummy file

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12815

--- Comment #2 from David Nadlinger c...@klickverbot.at ---
I also needed something like this a while back (also for input, though), so I
agree that having it in Phobos would be nice.

(In reply to Maksim Zholudev from comment #0)
 What about other systems?

NUL should do the trick on Windows, I think.

--


[Issue 13025] Tools repository does not build on Ubuntu

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13025

--- Comment #8 from David Nadlinger c...@klickverbot.at ---
(In reply to Martin Nowak from comment #7)
 Oh, I remember this one, but we actually did resolve it back then.

I meant unresolved as in we didn't actually figure out why the symbol
disappeared and just worked around it.

 Now the question is, why does linking with libcurl affect the linker provided 
 symbols.

Yep, this doesn't make a lot of sense. I guess we could always use the
workaround I described in issue 878 for --gc-sections to avoid these problems
and get the release out. If the DMD backend can emit weak symbols already, it
should be rather painless.

--


[Issue 12897] std.json.toJSON doesn't translate unicode chars(=0x80) to \uXXXX

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12897

Justin Whear jus...@economicmodeling.com changed:

   What|Removed |Added

 CC||jus...@economicmodeling.com

--- Comment #1 from Justin Whear jus...@economicmodeling.com ---
Looking at the spec
(http://www.ecma-international.org/publications/files/ECMA-ST/ECMA-404.pdf) it
appears that while strings _may_ encode characters using the escape sequence,
they are not _required_ to for any range of characters.  On the face of it it
seems that std.json is conformant and other languages are not.  Which parsers
are unable to handle the raw UTF-8?

--


[Issue 12969] std.json: Lack of opIndexAssign operator for JSONValue may become a source of runtime errors

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12969

Justin Whear jus...@economicmodeling.com changed:

   What|Removed |Added

 Status|NEW |ASSIGNED
 CC||jus...@economicmodeling.com

--- Comment #1 from Justin Whear jus...@economicmodeling.com ---
https://github.com/D-Programming-Language/phobos/pull/2269

--


[Issue 13097] linker error: undefined reference to symbol '_end', bisected to druntime 09ea3d

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13097

yazan.dab...@gmail.com changed:

   What|Removed |Added

 CC||yazan.dab...@gmail.com
   Severity|normal  |regression

--


[Issue 13100] New: std.process.setCLOEXEC() throws on invalid file descriptor

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13100

  Issue ID: 13100
   Summary: std.process.setCLOEXEC() throws on invalid file
descriptor
   Product: D
   Version: D2
  Hardware: All
OS: Linux
Status: NEW
  Severity: normal
  Priority: P1
 Component: Phobos
  Assignee: nob...@puremagic.com
  Reporter: bugzi...@kyllingen.net

This is based on a report I received by e-mail from a D user.

If a program that calls spawnProcess() is run in an environment where one or
more of the standard streams are closed, the setCLOEXEC() function will throw
an exception and the child process will terminate.

I will send a pull request that fixes this shortly.

--


[Issue 13025] Tools repository does not build on Ubuntu

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13025

--- Comment #9 from Martin Nowak c...@dawg.eu ---
OK, I could reproduce the issue with a few C files.
It seems to be caused by a diagnostic bug in the linker.
For some reason (optimized linker scipt, hidden visibility) libcurl.so does not
carry _end and __bss_start, but one of it's dependencies does, librtmp.so.
When the linker sees that the undefined symbols __bss_start/_end are
dynamically exported by librtmp it throws an error, telling you that you're not
linking against librtmp even though you rely on one of it's symbols.
You can suppress this warning with -unresolved-symbols=ignore-in-shared-libs
and everything will work as expected.

We cannot use the PROVIDE(edata = .) and PROVIDE(end = .) symbols, because then
libphobos.so would not point to the correct bss segment of the executable.
I think it should be possible to find the .bss segment of the executable in
sections_linux though.

--


[Issue 13100] std.process.setCLOEXEC() throws on invalid file descriptor

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13100

--- Comment #1 from Lars T. Kyllingstad bugzi...@kyllingen.net ---
https://github.com/D-Programming-Language/phobos/pull/2326

--


[Issue 13025] Tools repository does not build on Ubuntu

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13025

yazan.dab...@gmail.com changed:

   What|Removed |Added

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

--- Comment #10 from yazan.dab...@gmail.com ---
Related/duplicate issue: https://issues.dlang.org/show_bug.cgi?id=13097

--


[Issue 13025] Tools repository does not build on Ubuntu

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13025

Martin Nowak c...@dawg.eu changed:

   What|Removed |Added

 CC||zor...@gmail.com

--- Comment #11 from Martin Nowak c...@dawg.eu ---
*** Issue 13097 has been marked as a duplicate of this issue. ***

--


[Issue 13097] linker error: undefined reference to symbol '_end', bisected to druntime 09ea3d

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13097

Martin Nowak c...@dawg.eu changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||c...@dawg.eu
 Resolution|--- |DUPLICATE

--- Comment #1 from Martin Nowak c...@dawg.eu ---


*** This issue has been marked as a duplicate of issue 13025 ***

--


[Issue 3191] std.zlib.UnCompress errors if buffer is reused

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=3191

Justin Whear jus...@economicmodeling.com changed:

   What|Removed |Added

 CC||jus...@economicmodeling.com

--- Comment #3 from Justin Whear jus...@economicmodeling.com ---
The DEFLATE decompression algorithm relies on the results of previous blocks,
as it tries to reuse the encoding tree.  From the RFC: Note that a duplicated
string reference may refer to a string in a previous block; i.e., the backward
distance may cross one or more block boundaries. However a distance cannot
refer past the beginning of the output stream.
(http://www.w3.org/Graphics/PNG/RFC-1951#huffman)

So I think the bug should be clarified to this function allowing block reuse in
the first place.

--


[Issue 3191] std.zlib.UnCompress errors if buffer is reused

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=3191

--- Comment #4 from Justin Whear jus...@economicmodeling.com ---
I should note that some amount of block reuse is possible if the blocks are
sufficiently distant; the maximum distance for a back reference is 32,768
bytes.

--


[Issue 3821] writeln doesn't detect recursive data structures yet

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=3821

Justin Whear jus...@economicmodeling.com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||jus...@economicmodeling.com
 Resolution|--- |INVALID

--- Comment #4 from Justin Whear jus...@economicmodeling.com ---
Andrej: your updated example is invalid--two functions calling each other
should result in a stack overflow.

--


[Issue 12835] std.random.uniform with open lower bound cannot support smaller integral types or character types

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12835

--- Comment #3 from github-bugzi...@puremagic.com ---
Commits pushed to master at https://github.com/D-Programming-Language/phobos

https://github.com/D-Programming-Language/phobos/commit/88d86ecda0c53568e4c7036ec85aa7a5a27438f9
Fix Issue #12835: open lower bound for integral-type uniform()

Added a cast to ensure the setting of lower bound can handle character
types and integral types smaller than int.  The additional unittests
should prevent such issues from arising again.

https://github.com/D-Programming-Language/phobos/commit/9e96ee3d38b563fb70c8761a0ccee663d59810cc
Merge pull request #2221 from WebDrake/uniform-lowerbound

Fix Issue #12835: open lower bound for integral-type uniform()

--


[Issue 12835] std.random.uniform with open lower bound cannot support smaller integral types or character types

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12835

github-bugzi...@puremagic.com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED

--


[Issue 10748] ldc fails to build on arm

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=10748

David Nadlinger c...@klickverbot.at changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||c...@klickverbot.at
 Resolution|--- |INVALID

--- Comment #1 from David Nadlinger c...@klickverbot.at ---
Please use the LDC issue tracker for LDC-specific issues:
https://github.com/ldc-developers/ldc/issues?labels=B-arm

--


[Issue 13073] Wrong uint array comparison

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13073

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

   What|Removed |Added

   Keywords||pull

--- Comment #2 from hst...@quickfur.ath.cx ---
https://github.com/D-Programming-Language/druntime/pull/881

--


[Issue 3191] std.zlib.UnCompress errors if buffer is reused

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=3191

--- Comment #5 from Stewart Gordon s...@iname.com ---
(In reply to Justin Whear from comment #3)
 The DEFLATE decompression algorithm relies on the results of previous
 blocks, as it tries to reuse the encoding tree.  From the RFC: Note that a
 duplicated string reference may refer to a string in a previous block; i.e.,
 the backward distance may cross one or more block boundaries.

If I'm not mistaken, deflate blocks are independent of chunks that the
datastream may be split into for decompression.  (OK, maybe block was the
wrong word in my original bug report.)

That said,
(In reply to Justin Whear from comment #4)
 I should note that some amount of block reuse is possible if the blocks are
 sufficiently distant; the maximum distance for a back reference is 32,768
 bytes.

This says to me that it is a window of 32768 bytes (or maybe 32769 or 32770
bytes) that needs to be kept in memory at a given time, regardless of block or
chunk boundaries.  So why did I find that alternating between buffers works
even if the buffers are much smaller than this?  (Indeed, I've a vague
recollection of finding that it works if each of the buffers is a single byte.)

--


[Issue 3363] std.stream.readf segfaults with immutable format strings

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=3363

github-bugzi...@puremagic.com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED

--


[Issue 3363] std.stream.readf segfaults with immutable format strings

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=3363

--- Comment #3 from github-bugzi...@puremagic.com ---
Commits pushed to master at https://github.com/D-Programming-Language/phobos

https://github.com/D-Programming-Language/phobos/commit/141a088e378ac9b97f63ea044ff160a7c0310369
Fix issue 3363: std.stream.readf segfaults with immutabel format strings

https://github.com/D-Programming-Language/phobos/commit/911ea3144397665a3ddf282e2e38bca104f3f50e
Merge pull request #2224 from Hackerpilot/issue-3363

Fix issue 3363: std.stream.readf segfaults with immutable format strings

--


[Issue 13101] New: Cherry-picks for v2.066.0-rc1

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13101

  Issue ID: 13101
   Summary: Cherry-picks for v2.066.0-rc1
   Product: D
   Version: D2
  Hardware: All
OS: All
Status: NEW
  Severity: critical
  Priority: P1
 Component: DMD
  Assignee: nob...@puremagic.com
  Reporter: edwards...@gmail.com

Identify all regression fixes to be cherry-picked for v2.066.0-rc1. If there
are no cherry picks identified on this ticket by 0700 UTC ( PDT, 0300 EDT,
1600 JST) on 14 July 2014, the review period will be concluded and v2.066.0
prepared and released.

--


[Issue 13073] Wrong uint/int array comparison

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13073

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

   What|Removed |Added

Summary|Wrong uint array comparison |Wrong uint/int array
   ||comparison

--


[Issue 13073] Wrong uint array comparison

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13073

--- Comment #3 from hst...@quickfur.ath.cx ---
Comparison of int[] is also wrong; it uses subtraction, which is OK in terms of
sign handling, but wrong because of possibility of overflow (e.g., int.max -
int.min overflows and doesn't return a positive result).

--


[Issue 13100] std.process.setCLOEXEC() throws on invalid file descriptor

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13100

--- Comment #2 from github-bugzi...@puremagic.com ---
Commits pushed to master at https://github.com/D-Programming-Language/phobos

https://github.com/D-Programming-Language/phobos/commit/b7af42bafa7f4cdae415daf0d1e5bb212a40bd88
Fix issue #13100 - std.process.setCLOEXEC() throws

There are two cases in which the fcntl() calls may fail:

  1) the file descriptor is invalid, in which case errno == EBADF,
  2) they receive invalid arguments, in which case errno == EINVAL.

We just want to ignore the error in the former case, as evidenced by
the bug report, and the latter means that we have an error in
std.process, which is best handled by an assertion. (Note that it was
never possible to catch the exception anyway, since it was thrown in
the child process.)

https://github.com/D-Programming-Language/phobos/commit/357b627d2b7349c5fae8fc336f988242cd9fd51f
Merge pull request #2326 from kyllingstad/no-setcloexec-fail

Fix issue #13100 - std.process.setCLOEXEC() throws on invalid file descriptor

--


[Issue 13102] New: Cannot parse 184467440737095516153.6L

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13102

  Issue ID: 13102
   Summary: Cannot parse 184467440737095516153.6L
   Product: D
   Version: D2
  Hardware: x86_64
OS: Linux
Status: NEW
  Severity: regression
  Priority: P1
 Component: DMD
  Assignee: nob...@puremagic.com
  Reporter: timon.g...@gmx.ch

dmd-2.065.0/dmd-2.066.0-b2

enum e=184467440737095516153.6L;

fails with:

Error: integer overflow

This worked with dmd-2.064.

--


[Issue 12897] std.json.toJSON doesn't translate unicode chars(=0x80) to \uXXXX

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12897

--- Comment #2 from egu...@gmail.com ---
OK... I used Python but didn't decode first and got a problem. 

(In reply to Justin Whear from comment #1)
 Looking at the spec
 (http://www.ecma-international.org/publications/files/ECMA-ST/ECMA-404.pdf)
 it appears that while strings _may_ encode characters using the escape
 sequence, they are not _required_ to for any range of characters.  On the
 face of it it seems that std.json is conformant and other languages are not.
 Which parsers are unable to handle the raw UTF-8?

--


[Issue 13042] std.net.curl.SMTP doesn't send emails with libcurl-7.34.0 or newer

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13042

--- Comment #3 from github-bugzi...@puremagic.com ---
Commits pushed to master at https://github.com/D-Programming-Language/phobos

https://github.com/D-Programming-Language/phobos/commit/3f95468346f1eb42f27d18385ecfd5fae6887339
Fix Issue 13042 - std.net.curl.SMTP doesn't send emails with libcurl-7.34.0 or
newer

https://github.com/D-Programming-Language/phobos/commit/2206d5075df746a7da28ad3697f6f6514e5217ca
Merge pull request #2307 from brocolis/fix13042

Fix Issue 13042 - std.net.curl.SMTP doesn't send emails with libcurl-7.34.0 or
newer

--


[Issue 7648] std.stdio expects file names to be encoded in CP_ACP on Windows instead of UTF-8

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=7648

--- Comment #11 from github-bugzi...@puremagic.com ---
Commits pushed to master at https://github.com/D-Programming-Language/phobos

https://github.com/D-Programming-Language/phobos/commit/2932b9e7e5ee7c6eb6057bef61ab6be6065ed013
Fix bug 7648 comment in `std.stdio.File` and add bug section to
`std.file.slurp`.

Issue URL: http://d.puremagic.com/issues/show_bug.cgi?id=7648

https://github.com/D-Programming-Language/phobos/commit/ec51209c9faa97d0598bb5401fff636fa3ba7124
Merge pull request #1653 from denis-sh/fix-bug-7648-comments

Fix bug 7648 comment in `std.stdio.File` and add bug section to
`std.file.slurp`.

--


[Issue 7648] std.stdio expects file names to be encoded in CP_ACP on Windows instead of UTF-8

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=7648

github-bugzi...@puremagic.com changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED

--


[Issue 13103] New: struct initialization w/ null for Rebindable!(const Object) fails

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13103

  Issue ID: 13103
   Summary: struct initialization w/ null for Rebindable!(const
Object) fails
   Product: D
   Version: D2
  Hardware: x86_64
OS: Linux
Status: NEW
  Severity: normal
  Priority: P1
 Component: Phobos
  Assignee: nob...@puremagic.com
  Reporter: pro.mathias.l...@gmail.com

This code fails to compile under master
(2206d5075df746a7da28ad3697f6f6514e5217ca) and 2.065.0:

import std.typecons : Rebindable, rebindable;

struct Test {
Rebindable!(Object) obj;
Rebindable!(const Object) cobj;
}

void main()
{
Test t1; // Okay
Test t2 = Test(null); // Okay   
t2.cobj = null; // Still okay   
Test t3 = Test(null, null); // Error: cannot implicitly convert expression
(null) of type typeof(null) to Rebindable!(const(Object))   
}

--


[Issue 7648] std.stdio expects file names to be encoded in CP_ACP on Windows instead of UTF-8

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=7648

Brad Roberts bra...@puremagic.com changed:

   What|Removed |Added

 Status|RESOLVED|REOPENED
 CC||bra...@puremagic.com
 Resolution|FIXED   |---

--- Comment #12 from Brad Roberts bra...@puremagic.com ---
I'm reopening this since documentation != a fix.  The commit comment
incorrectly says fixed so github auto-closed the bug based on that.

--


[Issue 13073] Wrong uint/int array comparison

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13073

--- Comment #4 from github-bugzi...@puremagic.com ---
Commits pushed to master at https://github.com/D-Programming-Language/druntime

https://github.com/D-Programming-Language/druntime/commit/edbcce94acaa10fa0137bcec99f095a8e7c0ed8f
Add unittest for issue 13073.

https://github.com/D-Programming-Language/druntime/commit/b0920b65de2ff5c9b777642fc438691a59f63611
Merge pull request #881 from quickfur/issue13073

Fix wrong comparison of uint[]/int[] due to invalid subtraction.

--


[Issue 13073] Wrong uint/int array comparison

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13073

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

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED

--- Comment #5 from hst...@quickfur.ath.cx ---
Confirmed fixed in git HEAD.

--


[Issue 1985] import expression should return ubyte[] not string

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=1985

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

   What|Removed |Added

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

--


[Issue 1926] TypeInfo methods getHash, compare, equals unimplemented for AA, function and delegate

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=1926

--- Comment #4 from hst...@quickfur.ath.cx ---
Bug #10380 has been resolved; is this bug also fixed now, or is it still a
problem?

--


[Issue 2372] Template parameter types given as template parameter inhibits template instantiation + missing line number

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=2372

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

   What|Removed |Added

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

--- Comment #2 from hst...@quickfur.ath.cx ---
Still happens in git HEAD.

--


[Issue 13084] ModuleInfo.opApply delegate expects immutable parameter

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13084

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

   What|Removed |Added

 CC||bugzi...@digitalmars.com

--- Comment #4 from Walter Bright bugzi...@digitalmars.com ---
Hmm. Suppose we did this:

  alias immutable(_ModuleInfo) ModuleInfo;

?

--


[Issue 4459] bad format - phobos/std/all.d - 2.051

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=4459

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

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||hst...@quickfur.ath.cx
 Resolution|--- |WORKSFORME

--- Comment #5 from hst...@quickfur.ath.cx ---
In latest git HEAD, it's now posix.mak, and I haven't had problems compiling
phobos on Linux/64bit for at least 2 years now. Also, all.d doesn't even exist
anymore. So looks like this bug is obsolete.

If this is not the case, please reopen it. Thanks!

--


[Issue 5332] Undefined reference to zero length array

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=5332

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

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||hst...@quickfur.ath.cx
 Resolution|--- |WORKSFORME

--- Comment #8 from hst...@quickfur.ath.cx ---
Seems to have been fixed in git HEAD. Tested on Linux 64-bit, dmd revision
2cd115bb6738e884c19b32b1640b23ed25efc0d6. Please reopen if this still happens.

--


[Issue 5332] Undefined reference to zero length array

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=5332

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

   What|Removed |Added

 Status|RESOLVED|REOPENED
 Resolution|WORKSFORME  |---

--- Comment #9 from hst...@quickfur.ath.cx ---
Gah, nevermind, missed the note about fix only working for ELF.

--


[Issue 10693] cartesianProduct with over 7 ranges causes segfault at compile time

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=10693

--- Comment #8 from hst...@quickfur.ath.cx ---
Latest git HEAD no longer segfaults at compile-time (new cartesianProduct
implementation no longer uses exponential number of templates); but now a new
problem is exposed: an empty cartesianProduct triggers a range error at
runtime. Looks like a missing .empty check somewhere...

--


[Issue 7068] copying array of pointers calls memset instead of memcpy with -d

2014-07-11 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=7068

--- Comment #2 from github-bugzi...@puremagic.com ---
Commits pushed to master at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/9d6f4db34c426253892ba21d8e8728ce327867f4
Add regression test for bug 7068.

https://github.com/D-Programming-Language/dmd/commit/813ce694514adc8234ebb9cb7503e70774ef54ca
Merge pull request #3746 from Safety0ff/test7068

Add regression test for bug 7068.

--