[Issue 13512] Allow non-UTF-8 encoding in shebang line

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13512

--- Comment #18 from github-bugzi...@puremagic.com ---
Commits pushed to master at https://github.com/dlang/dmd

https://github.com/dlang/dmd/commit/9f50d033696d686f00527a8b5f8efbb358fc2245
Fix Issue 13512 - Allow non-UTF-8 encoding in shebang line

Adapted from https://issues.dlang.org/attachment.cgi?id=1431=diff

https://github.com/dlang/dmd/commit/c25d606e7d8db7ed36218328eb37853c79902f39
Add test case for issue 13512

>From https://issues.dlang.org/attachment.cgi?id=1430

https://github.com/dlang/dmd/commit/48d5ef139b4d1aa874a3094bcccd16114c3f3349
Merge pull request #6959 from CyberShadow/pull-20170702-145440

Fix Issue 13512 - Allow non-UTF-8 encoding in shebang line 
merged-on-behalf-of: Andrei Alexandrescu <andra...@users.noreply.github.com>

--


[Issue 6554] windows case insensitive imports

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=6554

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |WORKSFORME

--- Comment #2 from Vladimir Panteleev  ---
The error message is now much better:

test.d(4,12): Error: module std.bigint from file C:\...\std\bigInt.d must be
imported with 'import std.bigint;'

so I assume this can now be closed.

--


[Issue 17307] [REG2.072.0][ICE] TypeBasic::implicitConvTo: After error "anonymous struct can only be a part of an aggregate"

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17307

Vladimir Panteleev  changed:

   What|Removed |Added

 CC||dlang-bugzilla@thecybershad
   ||ow.net
Summary|[ICE]   |[REG2.072.0][ICE]
   |TypeBasic::implicitConvTo:  |TypeBasic::implicitConvTo:
   |After error "anonymous  |After error "anonymous
   |struct can only be a part   |struct can only be a part
   |of an aggregate"|of an aggregate"
   Severity|critical|regression

--- Comment #1 from Vladimir Panteleev  ---
This appears to be a regression.

Introduced in https://github.com/dlang/dmd/pull/5500

--


[Issue 10899] std.random.Random default RNG type should be customizable at compile-time

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=10899

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |WONTFIX

--- Comment #1 from Vladimir Panteleev  ---
Hmm, I don't think this is going to be implemented, because...

- Historically the BDFLs have been opposed by compiler switches which change
program behaviour.

- Changing the RNG globally may break existing code which used Random with a
fixed seed.

- As you've mentioned,

(In reply to Joseph Rushton Wakeling from comment #0)
> Caveats: Could a build-local customization of Random have implications for
> linking?  I guess redefining the alias itself is not a problem but there
> could also be problems with clashes in the namespace for rndGen.

Random is an alias, so any symbols which have Random in their signature will
have different mangling (and fully-resolved type) depending on the compile-time
Random version selected.

- This bug is close to 4 years old with no replies, so I doubt someone is going
to start working on this now.

--


[Issue 17467] BitArray are broken with <<= 64

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17467

Vladimir Panteleev  changed:

   What|Removed |Added

 CC||dlang-bugzilla@thecybershad
   ||ow.net
   Hardware|x86_64  |All
 OS|Mac OS X|All

--


[Issue 13980] We need better documentation for potential contributors

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13980

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |WORKSFORME

--- Comment #3 from Vladimir Panteleev  ---
(In reply to Andrei Alexandrescu from comment #2)
> That's on POSIX. Is there a Windows equivalent yet?

https://wiki.dlang.org/Building_under_Windows ?

--


[Issue 16999] takeOne popFront/Back does not pop the source range

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16999

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |WORKSFORME
 OS|Windows |All

--- Comment #4 from Vladimir Panteleev  ---
PR was merged, so I assume this is now fixed.

--


[Issue 15870] UFCS not recognized on array when passing as alias parameter

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=15870

Vladimir Panteleev  changed:

   What|Removed |Added

   Keywords||CTFE, rejects-valid
 CC||dlang-bugzilla@thecybershad
   ||ow.net
   Hardware|x86_64  |All
 OS|Linux   |All
   Severity|enhancement |normal

--


[Issue 14723] Typeinfo sent to GC does not retain storage class information

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=14723

Vladimir Panteleev  changed:

   What|Removed |Added

 CC||dlang-bugzilla@thecybershad
   ||ow.net
   Hardware|x86_64  |All
 OS|Linux   |All

--- Comment #1 from Vladimir Panteleev  ---
This looks like a very simple fix.

In Druntime, in rt.lifetime, in _d_newitemU, change:

auto blkInf = GC.qalloc(size, flags, ti);

to:

auto blkInf = GC.qalloc(size, flags, _ti);

If you still would like this changed, please submit a PR.

--


[Issue 17389] std.traits.hasNested fails for class with member of same type

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17389

--- Comment #2 from github-bugzi...@puremagic.com ---
Commit pushed to master at https://github.com/dlang/phobos

https://github.com/dlang/phobos/commit/95f6d5bff36f2f951e0df6e899e92dc27e8311e8
Fix Issue 17389 - hasNested infinite recursion

Happens with a class with a member of the same type.

--


[Issue 17389] std.traits.hasNested fails for class with member of same type

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17389

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

   What|Removed |Added

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

--


[Issue 8293] Small amount of static analysis to avoid certain destructor bugs

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=8293

--- Comment #3 from Vladimir Panteleev  ---
(In reply to Marco Leise from comment #2)
> Which more or less means that if such an object is allocated with new, there
> must always be a pointer to it to prevent automatic collection. Because it
> has to be manually destroyed to be safe.
> Or can the GC be improved in this regard?

Just use C malloc. This is what RefCounted!T does.

--


[Issue 17237] Wrong alignment of 256-bit and 512-bit vectors

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17237

Vladimir Panteleev  changed:

   What|Removed |Added

   See Also||https://issues.dlang.org/sh
   ||ow_bug.cgi?id=16087

--


[Issue 16087] Alignment (.alignof) and stack space incorrect for SIMD types.

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16087

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
   See Also||https://issues.dlang.org/sh
   ||ow_bug.cgi?id=17237
 Resolution|--- |WORKSFORME

--- Comment #4 from Vladimir Panteleev  ---
(In reply to Marco Leise from comment #0)
> writefln("float8.alignof yields %s but should yield 32.",
> float8.alignof);
> writefln("void16.alignof yields %s but should yield 16.",
> void16.alignof);

Fixed in https://github.com/dlang/dmd/pull/6265

> writefln("When embedded, a float4 exposes some hidden alignment, as it
> changes to %s.", Matrix4x4.alignof);

Fixed in https://github.com/dlang/dmd/pull/6582 (issue 17237)

--


[Issue 17586] New: Overriding a deprecated base class function gives no warning

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17586

  Issue ID: 17586
   Summary: Overriding a deprecated base class function gives no
warning
   Product: D
   Version: D2
  Hardware: All
OS: All
Status: NEW
  Severity: normal
  Priority: P1
 Component: dmd
  Assignee: nob...@puremagic.com
  Reporter: timon.g...@gmx.ch

The following code should give a deprecation warning:

class C{
deprecated void foo(){}
}

class D: C{
override void foo(){}  
}

--


[Issue 17584] Wrong error message for deprecated overrides

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17584

timon.g...@gmx.ch changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |INVALID

--- Comment #1 from timon.g...@gmx.ch ---
Accidentally created the issue twice.

--


[Issue 17585] New: Wrong error message for deprecated overrides

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17585

  Issue ID: 17585
   Summary: Wrong error message for deprecated overrides
   Product: D
   Version: D2
  Hardware: All
OS: All
Status: NEW
  Severity: normal
  Priority: P1
 Component: dmd
  Assignee: nob...@puremagic.com
  Reporter: timon.g...@gmx.ch

The code:

class C{
void foo(){}
}

class D: C{
deprecated override void foo(){}  
}

Yields:

Deprecation: function tt.D.foo deprecated functions cannot be annotated
@disable

That is not what is happening. The error message should instead be:

Deprecation: overridden functions cannot be deprecated

--


[Issue 17584] New: Wrong error message for deprecated overrides

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17584

  Issue ID: 17584
   Summary: Wrong error message for deprecated overrides
   Product: D
   Version: D2
  Hardware: x86_64
OS: Linux
Status: NEW
  Severity: enhancement
  Priority: P1
 Component: dmd
  Assignee: nob...@puremagic.com
  Reporter: timon.g...@gmx.ch

The code:

class C{
void foo(){}
}

class D: C{
deprecated override void foo(){}  
}

Yields:

Deprecation: function tt.D.foo deprecated functions cannot be annotated
@disable

That is not what is happening. The error message should instead be:

Deprecation: overridden functions cannot be deprecated

--


[Issue 8570] Tuples without named fields should implicitly convert to tuples with named fields when returned from a function

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=8570

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |WONTFIX

--- Comment #2 from Vladimir Panteleev  ---
Reduced:

struct S { this(int) {} }

void bar()
{
S s = 5;
}

S foo()
{
return 5;
}

The first is an initialization / assignment; the second is an implicit
conversion. Currently D does not allow defining implicit conversions to
arbitrary types (closest is alias this, but it can alias only specific types).

Providing some way for types to do implicit conversions to arbitrary other
types is a much bigger discussion outside of the scope of this issue.

--


[Issue 13207] Wrong code for 'extern' C/C++ function returning struct

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13207

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |INVALID

--- Comment #3 from Vladimir Panteleev  ---
These test cases are very badly incomplete. The C source code is incomplete, it
is at least missing includes to things obviously used in the presented code,
but I'm also getting numerous other errors. There are no command lines. There
are no compiler versions. There is no compiler or linker output.

I am closing this because this is very far from being reproducible and was
filed 3 years ago. Please reopen if you can post complete, self-contained,
reproducible test cases.

--


[Issue 5628] std.math unittest disabled - roundoff error in pow() on SSE2

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=5628

--- Comment #6 from Vladimir Panteleev  ---
Here is the extracted test case from std.math:

void main()
{
import std.math;

immutable real x = 46;
immutable float xf = x;
immutable double xd = x;

immutable short neg2 = -2;
immutable long neg8 = -8;

assert(pow(xd, neg2) == 1 / (x * x));
assert(pow(xf, neg8) == 1 / ((x * x) * (x * x) * (x * x) * (x * x)));
}

--


[Issue 13060] @nogc reading an associative array

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13060

Vladimir Panteleev  changed:

   What|Removed |Added

   Hardware|x86 |All
 OS|Windows |All

--- Comment #1 from Vladimir Panteleev  ---
If the index is not in the AA, then a RangeError is thrown. The error is
currently allocated on the GC heap.

The "in" operator is @nogc, though.

--


[Issue 14627] Implicit conversion from uint to dchar allows dchar > dchar.max

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=14627

Vladimir Panteleev  changed:

   What|Removed |Added

   Priority|P1  |P3
   Hardware|x86 |All
 OS|Mac OS X|All

--


[Issue 6760] Disallow disabled overrides

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=6760

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |WORKSFORME

--- Comment #6 from Vladimir Panteleev  ---
6570 was merged, so this looks fixed.

--


[Issue 16645] 3 errors messages instead of 1 after CTFE divide by 0

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16645

Vladimir Panteleev  changed:

   What|Removed |Added

   Keywords||diagnostic
 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |WORKSFORME

--- Comment #1 from Vladimir Panteleev  ---
Introduced in https://github.com/dlang/dmd/pull/3602
Went from 3 to 2 errors in https://github.com/dlang/dmd/pull/6579
Fixed in https://github.com/dlang/dmd/pull/6917

--


[Issue 16200] Faster pow implementation for integral exponents

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16200

Vladimir Panteleev  changed:

   What|Removed |Added

 CC||dlang-bugzilla@thecybershad
   ||ow.net
  Component|dmd |phobos
   Hardware|x86_64  |All
 OS|Linux   |All

--- Comment #1 from Vladimir Panteleev  ---
(In reply to Andrei Alexandrescu from comment #0)
> Stepanov discusses

(to clarify, that's Alex Stepanov, not related to D contributor Igor Stepanov)

--


[Issue 15582] Slice returned by opSlice() not accepted as lvalue

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=15582

Vladimir Panteleev  changed:

   What|Removed |Added

   Hardware|x86_64  |All
 OS|Linux   |All

--


[Issue 15368] Improve error message for "auto" keyword inside "foreach"

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=15368

Vladimir Panteleev  changed:

   What|Removed |Added

   Keywords||diagnostic

--


[Issue 13470] Crash with final struct containing anonymous union

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13470

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |INVALID

--- Comment #2 from Vladimir Panteleev  ---
Incomplete testcase, no reply in 2 years, closing.

--


[Issue 8995] `is( == function)` creates tuple with parameter storage classes

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=8995

Vladimir Panteleev  changed:

   What|Removed |Added

   Keywords||spec
 CC||dlang-bugzilla@thecybershad
   ||ow.net

--


[Issue 8995] `is( == function)` creates tuple with parameter storage classes

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=8995

Vladimir Panteleev  changed:

   What|Removed |Added

 CC|dlang-bugzilla@thecybershad |
   |ow.net  |

--


[Issue 12059] Smarter error messages when a module contains a namespace with the same name

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12059

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |DUPLICATE

--- Comment #2 from Vladimir Panteleev  ---
The error message was improved in https://github.com/dlang/dmd/pull/4510.

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

--


[Issue 14320] Improve diagnostic message for "undefined identifier" error

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=14320

Vladimir Panteleev  changed:

   What|Removed |Added

 CC||bearophile_h...@eml.cc

--- Comment #4 from Vladimir Panteleev  ---
*** Issue 12059 has been marked as a duplicate of this issue. ***

--


[Issue 12068] `enum` as `inout` function parameter isn't enough for `inout` return.

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12068

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
   See Also||https://issues.dlang.org/sh
   ||ow_bug.cgi?id=15762
 Resolution|--- |WORKSFORME

--- Comment #2 from Vladimir Panteleev  ---
Fixed by https://github.com/dlang/dmd/pull/5878.

--


[Issue 15762] Array casts involving const enums can be made @safe

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=15762

Vladimir Panteleev  changed:

   What|Removed |Added

   See Also||https://issues.dlang.org/sh
   ||ow_bug.cgi?id=12068

--


[Issue 16674] Clarify lifetime of pointer to AA entry

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16674

Vladimir Panteleev  changed:

   What|Removed |Added

   Keywords||spec

--


[Issue 16968] Error.bypassedException is always null

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16968

Vladimir Panteleev  changed:

   What|Removed |Added

   Keywords||pull
 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |WORKSFORME

--- Comment #1 from Vladimir Panteleev  ---
I see https://github.com/dlang/druntime/pull/1712 is merged, closing.

--


[Issue 15505] extern(C++) array parameter mangling gains surprise const

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=15505

Vladimir Panteleev  changed:

   What|Removed |Added

   Keywords||C++
   Hardware|x86_64  |All
   Severity|enhancement |normal

--- Comment #1 from Vladimir Panteleev  ---
Only occurs when targeting the MS toolchain (-m64 / -m32mscoff).

-m32mscoff:
mangled: ?f@@YAXQAY03H@Z
demangled: void __cdecl f(int (* const)[4])

-m64:
mangled: ?f@@YAXQEAY03H@Z
demangled: void __cdecl f(int (* __ptr64 const)[4])

--


[Issue 6207] Mixin template evaluated to string can convert to string mixin expression implicitly

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=6207

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |WONTFIX

--- Comment #5 from Vladimir Panteleev  ---
(In reply to Walter Bright from comment #3)
> See the pull request for more discussion.

I believe such a change today would require a DIP, so I'm going to close this.

--


[Issue 12239] "undefined identifier" with named import and circular reference

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12239

Vladimir Panteleev  changed:

   What|Removed |Added

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

--- Comment #1 from Vladimir Panteleev  ---
Fixed by https://github.com/dlang/dmd/pull/5333.

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

--


[Issue 15519] Circular imports leads to fwd ref error with aliased imports

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=15519

Vladimir Panteleev  changed:

   What|Removed |Added

 CC||dlang-bugzilla@thecybershad
   ||ow.net

--- Comment #5 from Vladimir Panteleev  ---
*** Issue 12239 has been marked as a duplicate of this issue. ***

--


[Issue 17080] Can assign member-function-ptr to free-function-ptr

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17080

Vladimir Panteleev  changed:

   What|Removed |Added

   Hardware|x86_64  |All
 OS|Linux   |All

--


[Issue 2484] Templated classes have no moduleinfo

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=2484

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
   Hardware|x86 |All
 Resolution|--- |WONTFIX
 OS|Windows |All

--- Comment #9 from Vladimir Panteleev  ---
I believe we are moving away from Object.factory, so I doubt anything major
will change here.

Today, D's introspection capabilities allow building reflection information at
compile-time and using it at run-time, thus allowing users to build their own
Object.factory equivalents with the capabilities they need.

--


[Issue 15892] Can't use alias this with static namespaces

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=15892

Vladimir Panteleev  changed:

   What|Removed |Added

   Hardware|x86 |All
 OS|Windows |All

--


[Issue 10317] (2.063): Recursive error within Phobos

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=10317

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |WORKSFORME

--- Comment #10 from Vladimir Panteleev  ---
(In reply to Andrej Mitrovic from comment #9)
> The library fix is in place, but we still have to figure out why 2.062
> doesn't exhibit the same behavior even though it has the same library code.
> So I'm downgrading this to a normal bug to avoid blocking the .2 release

As no reproducible test case has materialized in the past 4 years, closing.

FWIW, this regression was initially introduced in
https://github.com/dlang/dmd/pull/1760.

--


[Issue 17004] std.containers should be usable with @nogc

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17004

Vladimir Panteleev  changed:

   What|Removed |Added

  Component|installer   |phobos
   Hardware|x86_64  |All
 OS|Linux   |All

--


[Issue 17583] New: Revive tools/pr/194 - compile the root module in the same step as getting the dependencies

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17583

  Issue ID: 17583
   Summary: Revive tools/pr/194 -  compile the root module in the
same step as getting the dependencies
   Product: D
   Version: D2
  Hardware: All
OS: All
Status: NEW
  Severity: enhancement
  Priority: P1
 Component: tools
  Assignee: nob...@puremagic.com
  Reporter: greensunn...@gmail.com

The PR https://github.com/dlang/tools/pull/194 got reverted due to a
regression. As rdmd is a widely used tool reviving it would have a positive
impact on many people.

FWIW it seems that integrating rdmd into dmd is still far ahead in the future.

--


[Issue 12802] Allow optional 'StorageClasses' for new alias syntax

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12802

Vladimir Panteleev  changed:

   What|Removed |Added

 CC||ibuc...@gdcproject.org

--- Comment #5 from Vladimir Panteleev  ---
*** Issue 12055 has been marked as a duplicate of this issue. ***

--


[Issue 12055] Error: basic type expected, not extern when using 'alias = function'

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12055

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |DUPLICATE

--- Comment #3 from Vladimir Panteleev  ---
Fixed by https://github.com/dlang/dmd/pull/3585.

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

--


[Issue 15648] Destructor constness doesn't take member destructor attributes into account

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=15648

Vladimir Panteleev  changed:

   What|Removed |Added

 CC||dlang-bugzilla@thecybershad
   ||ow.net
   Hardware|x86_64  |All
 OS|Linux   |All

--- Comment #1 from Vladimir Panteleev  ---
I believe the operation destroy(x) where x is an immutable value type was never
supported, as part of destroy's operation is to clobber the value of x with its
.init value - see object.d, the `void destroy(T)(ref T obj) if (is(T ==
struct))` overload. 

Changing the destroy() call with an explicit invocation of the inclusive
destructor (`keys[0].__xdtor();`) does seem to illustrate the problem better, I
think - the inclusive destructor should have its constness inferred from the
destructors it calls:

$ cat test.d 
struct HashTable
{
immutable(Key)* keys;

~this()
{
keys[0].__xdtor();
}
}

struct Key
{
KeyData data;
~this() const {}
}

struct KeyData
{
~this() const {}
}

$ dmd -o- test.d
test.d(7): Error: mutable method test.Key.~this is not callable using a
immutable object

--


[Issue 13512] Allow non-UTF-8 encoding in shebang line

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13512

Vladimir Panteleev  changed:

   What|Removed |Added

   Keywords||pull

--- Comment #17 from Vladimir Panteleev  ---
https://github.com/dlang/dmd/pull/6959

--


[Issue 13512] Allow non-UTF-8 encoding in shebang line

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13512

Vladimir Panteleev  changed:

   What|Removed |Added

 CC||dlang-bugzilla@thecybershad
   ||ow.net
Summary|dmd cannot compile  |Allow non-UTF-8 encoding in
   |perfectly valid code with   |shebang line
   |shebang |

--


[Issue 9360] Bad error message with non-const template method

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=9360

Vladimir Panteleev  changed:

   What|Removed |Added

   Keywords||diagnostic
 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
   Hardware|x86_64  |All
 Resolution|--- |WORKSFORME
 OS|Windows |All

--- Comment #1 from Vladimir Panteleev  ---
Since https://github.com/dlang/dmd/pull/1409, the error message now mentions
const, so this should be clearer.

--


[Issue 9086] std.typecons.appendIfNotNull() or a better idea

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=9086

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |WORKSFORME

--- Comment #4 from Vladimir Panteleev  ---
(In reply to bearophile_hugs from comment #0)
> A problem with std.typecons.Nullable is that the D type system is not
> powerful enough to see this is correct code:

This example now compiles fine.

Fixed in https://github.com/dlang/phobos/pull/1103

--


[Issue 17246] [REG2.053] Extra destructor call.

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17246

Vladimir Panteleev  changed:

   What|Removed |Added

 CC||dlang-bugzilla@thecybershad
   ||ow.net
Summary|Extra destructor call.  |[REG2.053] Extra destructor
   ||call.
   Severity|critical|regression

--- Comment #1 from Vladimir Panteleev  ---
Same example with asserts replacing writelns, and checks based on simple
reference counting:

struct Foo
{
int* rc;
this(int val)
{
rc = new int;
(*rc) = 1;
}
this(this)
{
(*rc)++;
}
~this()
{
if (rc)
{
assert(*rc > 0);
(*rc)--;
}
}
}

struct Bar
{
Foo foo;
this(Foo foo, bool)
{
this.foo = foo;
}
}

bool fun(bool val) { return !val; }

auto genBar(bool flag)
{
return flag ? Bar() : Bar(Foo(10), fun(!flag));
}

void main(string[] args)
{
auto bar = genBar(args.length == 0);
}

This appears to be a regression, as it worked before 2.052.

Introduced in
https://github.com/dlang/dmd/commit/e764b3949ae0f95f8fc4d7d2e9114e29fee12493

--


[Issue 2005] dynamic va_arg looping/ align info in TypeInfo

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=2005

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |WONTFIX

--- Comment #1 from Vladimir Panteleev  ---
As I understand, C-style variadics are provided in D only as a low-level
interoperability feature with existing C code. Today, variadic IFTI template
functions should be used instead in D code.

(In reply to Fawzi Mohamed from comment #0)
> Such functions could be readily implemented for dmd if typeinfo would give
> access to the alignment information of its type (.talign?).

TypeInfo.talign was added in
https://github.com/dlang/druntime/commit/cbd538f34f8082cc512a05eae3ab23039d8fe1d7.

--


[Issue 13471] CTFE glitch when executing std.digest.crc.crc32Of() and checking the result with enforce(). (keyword: uninitialized variable)

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13471

Vladimir Panteleev  changed:

   What|Removed |Added

   Keywords||diagnostic

--


[Issue 16621] [REG2.060] DMD hang in semantic3 on alias this or segfault

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16621

Vladimir Panteleev  changed:

   What|Removed |Added

 CC||dlang-bugzilla@thecybershad
   ||ow.net
Summary|DMD hang in semantic3 on|[REG2.060] DMD hang in
   |alias this or segfault  |semantic3 on alias this or
   ||segfault
   Severity|major   |regression

--- Comment #1 from Vladimir Panteleev  ---
(In reply to Daniel Kozak from comment #0)
> hang code example:

This one seems to be a regression.

Introduced in https://github.com/dlang/dmd/pull/890

> segfault example:

This one was always there.

--


[Issue 15868] Inappropriate error message: "base type must be class or interface" (and it is)

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=15868

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |DUPLICATE

--- Comment #1 from Vladimir Panteleev  ---
Fixed by https://github.com/dlang/dmd/pull/5333.

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

--


[Issue 15519] Circular imports leads to fwd ref error with aliased imports

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=15519

Vladimir Panteleev  changed:

   What|Removed |Added

 CC||andy.pj.han...@gmail.com

--- Comment #4 from Vladimir Panteleev  ---
*** Issue 15868 has been marked as a duplicate of this issue. ***

--


[Issue 7443] Better diagnostic on wrongly written static constructor

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=7443

Vladimir Panteleev  changed:

   What|Removed |Added

   Keywords||accepts-invalid,
   ||link-failure
 CC||dlang-bugzilla@thecybershad
   ||ow.net
   Severity|enhancement |normal

--- Comment #1 from Vladimir Panteleev  ---
To clarify, the example given currently (wrongly) compiles but fails to link
due to a "multiple definition" error.

Upgrading from enhancement since it seems like an accepts-invalid.

--


[Issue 13532] std.regex performance (enums; regex vs ctRegex)

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13532

--- Comment #6 from Vladimir Panteleev  ---
2017 timings with LDC 1.2.0 (DMD v2.072.2, LLVM 4.0.0):

regexInline7 secs, 342 ms, 775 μs, and 9 hnsecs
regexAuto5 secs, 195 ms, and 526 μs
regexStatic5 secs, 158 ms, 479 μs, and 2 hnsecs
regexEnum18 secs, 777 ms, 420 μs, and 7 hnsecs
ctRegexInline20 secs, 38 ms, and 25 μs
ctRegexAuto6 secs, 16 ms, 155 μs, and 1 hnsec
ctRegexStatic5 secs, 921 ms, 572 μs, and 3 hnsecs
ctRegexEnum20 secs, 422 ms, 889 μs, and 4 hnsecs
reInline5 secs, 84 ms, 943 μs, and 1 hnsec

--


[Issue 10810] wrong forward reference error when using return type deduction and a cyclic call flow

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=10810

--- Comment #6 from timon.g...@gmx.ch ---
(In reply to Vladimir Panteleev from comment #5)
> (In reply to timon.gehr from comment #3)
> > Currently, this is quite conservative. Analysis of any function is suspended
> > if a function call with unresolved return type is encountered, until this
> > return type has been resolved.
> 
> Short-circuiting return type analysis to "void" if there are no return
> statements in the body seems like a reasonable way to solve this particular
> case to me.

The compiler does not know whether there are any return statements in the body
when starting the analysis of a function because of conditional compilation and
string mixins.

--


[Issue 12669] autotester: Weekly Issues resolved graph is out of bounds

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=12669

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |WORKSFORME

--- Comment #2 from Vladimir Panteleev  ---
(In reply to hsteoh from comment #1)
> Where's the code that specifies the graph specs?

It's here:
https://github.com/braddr/d-tester/blob/master/server/chart.ghtml

That file has received a bunch of updates since this issue was filed, and I
don't see it manifesting right now, so I assume it has been resolved.

--


[Issue 16104] Unions should allow fields with destructors, postblits, and invariants

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16104

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
   See Also||https://issues.dlang.org/sh
   ||ow_bug.cgi?id=2665,
   ||https://issues.dlang.org/sh
   ||ow_bug.cgi?id=4144
 Resolution|--- |WORKSFORME

--- Comment #5 from Vladimir Panteleev  ---
I believe this was fixed in https://github.com/dlang/dmd/pull/5830.

BTW, the example in the description has a non-trivial history:

.. before 2.063 : test.d(24): Error: mutable method test.A1.opAssign is not
callable using a immutable object

Fixed  by: https://github.com/dlang/dmd/pull/2665 (issue 9665)

2.064 ... 2.066 : works

Broken by: https://github.com/dlang/dmd/pull/4144 (issue 4421)

2.067 ... 2.071 : test.d(12): Error: struct test.B destructors, postblits and
invariants are not allowed in overlapping fields a1 and a2

Fixed  by: https://github.com/dlang/dmd/pull/5830

2.072 ... now   : works

--


[Issue 2665] ICE(cod4.c) on certain const struct function return types

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=2665

Vladimir Panteleev  changed:

   What|Removed |Added

   See Also||https://issues.dlang.org/sh
   ||ow_bug.cgi?id=16104

--


[Issue 4144] Better line number of semicolon expected errors

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=4144

Vladimir Panteleev  changed:

   What|Removed |Added

   See Also||https://issues.dlang.org/sh
   ||ow_bug.cgi?id=16104

--


[Issue 10810] wrong forward reference error when using return type deduction and a cyclic call flow

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=10810

--- Comment #5 from Vladimir Panteleev  ---
(In reply to timon.gehr from comment #3)
> Currently, this is quite conservative. Analysis of any function is suspended
> if a function call with unresolved return type is encountered, until this
> return type has been resolved.

Short-circuiting return type analysis to "void" if there are no return
statements in the body seems like a reasonable way to solve this particular
case to me.

--


[Issue 14795] Allow user types implementing opEquals/toHash in switch statements

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=14795

Vladimir Panteleev  changed:

   What|Removed |Added

Summary|Extending D's switch|Allow user types
   |statement   |implementing
   ||opEquals/toHash in switch
   ||statements

--


[Issue 14967] std.xml.Tag doesn't include attributes in comparison

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=14967

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
   See Also||https://issues.dlang.org/sh
   ||ow_bug.cgi?id=10381
 Resolution|--- |INVALID

--- Comment #1 from Vladimir Panteleev  ---
std.xml.Tag.opEquals is defined as:

override bool opEquals(scope Object o)
{
const tag = toType!(const Tag)(o);
return
(name != tag.name) ? false : (
(attr != tag.attr) ? false : ( // <---
(type != tag.type) ? false : (
true )));
}

For opCmp, it compares the AA's pointer, and refers to issue 10381.

When reporting a bug, please always provide a self-contained, reproducible test
case which exhibits the current and desired behaviour, unless you plan to work
on the bug yourself. Incomplete bug reports will be closed; please reopen if
you can post an example as described above.

--


[Issue 10381] Nonsense associative array comparison

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=10381

Vladimir Panteleev  changed:

   What|Removed |Added

   See Also||https://issues.dlang.org/sh
   ||ow_bug.cgi?id=14967

--


[Issue 13782] gdc - fails to compile. Unrecognized option "-plugin"

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13782

Vladimir Panteleev  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 CC||dlang-bugzilla@thecybershad
   ||ow.net
 Resolution|--- |INVALID

--- Comment #1 from Vladimir Panteleev  ---
GDC bugs are tracked in a separate Bugzilla instance:

https://bugzilla.gdcproject.org/index.cgi

If this bug is still relevant, please file it there.

--


[Issue 17445] [REG2.073.0] Disagreement between 'static assert' and 'static if'

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17445

--- Comment #7 from Vladimir Panteleev  ---
(In reply to Vladimir Panteleev from comment #6)
> Introduced in https://github.com/dlang/dmd/pull/6388

Specifically:

https://github.com/dlang/dmd/pull/5972 (PR to scope branch)
Commit 62be2fbda0a09e1a5dd1fa6024f81c165057d386

--


[Issue 17582] [REG2.059] Applying const to struct declaration should make the struct type const

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17582

Vladimir Panteleev  changed:

   What|Removed |Added

Summary|Applying const to struct|[REG2.059] Applying const
   |declaration should make the |to struct declaration
   |struct type const   |should make the struct type
   ||const

--


[Issue 17581] Document behavior of -betterC

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17581

Vladimir Panteleev  changed:

   What|Removed |Added

   Keywords||spec
   Hardware|x86_64  |All
 OS|Linux   |All

--


[Issue 13767] Cannot partially destructure type qualifiers with == form of IsExpression

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=13767

Vladimir Panteleev  changed:

   What|Removed |Added

   Keywords||spec
 Status|RESOLVED|REOPENED
 Resolution|INVALID |---
Summary|Template type inference |Cannot partially
   |fails when destructuring|destructure type qualifiers
   |shared type |with == form of
   ||IsExpression

--- Comment #3 from Vladimir Panteleev  ---
(In reply to monkeyworks12 from comment #2)
> I'm assuming in your example you meant to use : instead of ==.

Oops, yes.

> That aside, why shouldn't this work? I'm trying to destructure some type
> which matches the pattern `shared U`. `shared const(int)` *should* match
> that pattern. What I'm trying to express is `∃ U: shared U == shared const
> int`; it seems incorrect to me that that I should have to use the subtyping
> form of is.

OK, I see what you mean now. It looks like partial destructuring of type
qualifiers was never implemented for == variants of IsExpression. It is the
same for inout:

static assert(!is(shared const int == shared U, U)); // should work
static assert( is(shared const int :  shared U, U));
static assert(!is(inout  const int == const  U, U)); // should work
static assert( is(inout  const int :  const  U, U));

--


[Issue 4713] PATCH for interface generation: cleanup, bugfixes and prettyprinting

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=4713

Norbert Nemec  changed:

   What|Removed |Added

 Status|RESOLVED|CLOSED
 Resolution|WORKSFORME  |WONTFIX

--- Comment #3 from Norbert Nemec  ---
Indeed, this is so ancient, there is no point spending any time on it now...

--


[Issue 17582] Applying const to struct declaration should make the struct type const

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17582

Walter Bright  changed:

   What|Removed |Added

   Severity|normal  |regression

--- Comment #1 from Walter Bright  ---
Regression introduced by:

https://github.com/dlang/dmd/pull/783

--


[Issue 17582] New: Applying const to struct declaration should make the struct type const

2017-07-02 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17582

  Issue ID: 17582
   Summary: Applying const to struct declaration should make the
struct type const
   Product: D
   Version: D2
  Hardware: All
OS: All
Status: NEW
  Severity: normal
  Priority: P1
 Component: dmd
  Assignee: nob...@puremagic.com
  Reporter: bugzi...@digitalmars.com

The following should compile:

  const struct S {
int x;
  }

  static assert(is(S == const(S)));

--