[Issue 21004] dmd segmentation fault with 'void' struct member array initializer
https://issues.dlang.org/show_bug.cgi?id=21004 Basile-z changed: What|Removed |Added Keywords||ice --
[Issue 21004] dmd segmentation fault with 'void' struct member array initializer
https://issues.dlang.org/show_bug.cgi?id=21004 RazvanN changed: What|Removed |Added CC||razvan.nitu1...@gmail.com Severity|normal |major --
[Issue 21001] Private alias becomes public if used before declaration
https://issues.dlang.org/show_bug.cgi?id=21001 Dlang Bot changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #1 from Dlang Bot --- dlang/dmd pull request #11356 "Fix issue 21001: alias protection is ignored if used before declaration." was merged into master: - 7a3a2e3af7810c812d691d941bfe3ae892f678cd by Mathis Beer: Fix issue 21001: alias protection is ignored if used before declaration. https://github.com/dlang/dmd/pull/11356 --
[Issue 12504] Wrong 'cannot cover index range' error message
https://issues.dlang.org/show_bug.cgi?id=12504 Dlang Bot changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #4 from Dlang Bot --- dlang/dmd pull request #11359 "fix issue 12504 - Wrong 'cannot cover index range' error message" was merged into stable: - 23693e8699a319e1175b6516df3f4c309561c3da by Nils Lankila: fix issue 12504 - Wrong 'cannot cover index range' error message https://github.com/dlang/dmd/pull/11359 --
[Issue 21006] core.internal.hash.bytesHash: in 64-bit builds use a 64-bit-oriented algorithm
https://issues.dlang.org/show_bug.cgi?id=21006 Dlang Bot changed: What|Removed |Added Keywords||pull --- Comment #1 from Dlang Bot --- @n8sh created dlang/druntime pull request #3148 "core.internal.hash.bytesHash: in 64-bit builds use a 64-bit-oriented algorithm" fixing this issue: - Fix Issue 21006 - core.internal.hash.bytesHash: in 64-bit builds use a 64-bit-oriented algorithm https://github.com/dlang/druntime/pull/3148 --
[Issue 21007] DMD generates unnecessary prolog/epilog for trivial functions
https://issues.dlang.org/show_bug.cgi?id=21007 Walter Bright changed: What|Removed |Added Keywords||performance --
[Issue 21007] New: DMD generates unnecessary prolog/epilog for trivial functions
https://issues.dlang.org/show_bug.cgi?id=21007 Issue ID: 21007 Summary: DMD generates unnecessary prolog/epilog for trivial functions 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 code: int square(int num) { return num * num; } generates: pushRBP mov RBP,RSP mov EAX,EDI imulEAX,EAX pop RBP ret while gdc and ldc do not generate the prolog/epilog. https://godbolt.org/z/A7EUu7 --
[Issue 21006] New: core.internal.hash.bytesHash: in 64-bit builds use a 64-bit-oriented algorithm
https://issues.dlang.org/show_bug.cgi?id=21006 Issue ID: 21006 Summary: core.internal.hash.bytesHash: in 64-bit builds use a 64-bit-oriented algorithm Product: D Version: D2 Hardware: x86_64 OS: All Status: NEW Severity: enhancement Priority: P1 Component: druntime Assignee: nob...@puremagic.com Reporter: n8sh.second...@hotmail.com Currently all builds use 32-bit MurmurHash3 for core.internal.hash.bytesHash. On 64-bit builds this means the high 32 bits of the initial seed are discarded (which is relevant for chained uses of hashOf) and only the low 32 bits of the output are populated. In addition to fixing those problems speed improvement is also possible. --
[Issue 21005] Speed up hashOf for associative arrays
https://issues.dlang.org/show_bug.cgi?id=21005 --- Comment #1 from Dlang Bot --- @n8sh created dlang/druntime pull request #3147 "Issue 21005 - Speed up hashOf for associative arrays" mentioning this issue: - Issue 21005 - Speed up hashOf for associative arrays https://github.com/dlang/druntime/pull/3147 --
[Issue 21005] New: Speed up hashOf for associative arrays
https://issues.dlang.org/show_bug.cgi?id=21005 Issue ID: 21005 Summary: Speed up hashOf for associative arrays Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: enhancement Priority: P1 Component: druntime Assignee: nob...@puremagic.com Reporter: n8sh.second...@hotmail.com Current code: --- size_t h = 0; foreach (key, ref val; aa) { size_t[2] hpair; hpair[0] = key.hashOf(); hpair[1] = val.hashOf(); h += hpair.hashOf(); } --- Proposed code: --- size_t h = 0; foreach (ref key, ref val; aa) h += hashOf(hashOf(val), hashOf(key)); --- On a 32-bit machine the old code is equivalent to: --- size_t h = 0; foreach (key, ref val; aa) { size_t k = hashOf(hashOf(key), 0); k = hashOf(hashOf(val), h); k = fmix32(k ^ (size_t.sizeof * 2)); // fmix32 being the MurmurHash3 finalizer. h += k; } --- On a 64-bit machine the work involved is greater. That level of mixing at each step is excessive. Note: Writing `hashOf(val, hashOf(key))` might seem better than `hashOf(hashOf(key), hashOf(key))` as it possibly avoids redundancy, but that can't be used by the TypeInfo-based hash in rt.aaA._aaGetHash. --
[Issue 21004] New: dmd segmentation fault with 'void' struct member array initializer
https://issues.dlang.org/show_bug.cgi?id=21004 Issue ID: 21004 Summary: dmd segmentation fault with 'void' struct member array initializer Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW Severity: normal Priority: P1 Component: dmd Assignee: nob...@puremagic.com Reporter: acehr...@yahoo.com Compiling the following code segfaults dmd 2.092.0: struct S { ubyte[1024 * 1024] a = void; } void main() { version (works) { S s; } else { auto s = S();// Fails } } Compile it with `-version=works' and now it compiles fine. Array size does matter. You may have to use a different size to duplicate. Perhaps related to https://issues.dlang.org/show_bug.cgi?id=17874 Ali --
[Issue 12504] Wrong 'cannot cover index range' error message
https://issues.dlang.org/show_bug.cgi?id=12504 Dlang Bot changed: What|Removed |Added Keywords||pull --- Comment #3 from Dlang Bot --- @NilsLankila updated dlang/dmd pull request #11359 "fix issue 12504 - Wrong 'cannot cover index range' error message" fixing this issue: - fix issue 12504 - Wrong 'cannot cover index range' error message https://github.com/dlang/dmd/pull/11359 --
[Issue 1793] Error on debug specification mixin
https://issues.dlang.org/show_bug.cgi?id=1793 Basile-z changed: What|Removed |Added Version|D1 (retired)|D2 --
[Issue 7432] DMD allows variables to be declared as pure
https://issues.dlang.org/show_bug.cgi?id=7432 Basile-z changed: What|Removed |Added Keywords|rejects-valid |accepts-invalid CC||b2.t...@gmx.com --
[Issue 7273] Tuples conversion assign
https://issues.dlang.org/show_bug.cgi?id=7273 Basile-z changed: What|Removed |Added Keywords|rejects-valid | CC||b2.t...@gmx.com Hardware|x86 |All OS|Windows |All --- Comment #3 from Basile-z --- associated key word is wrong. It's like saying that --- struct S(T){} static assert (is(S!(int) == S!(immutable(int))) --- would be a "rejects-valid". --
[Issue 21003] Lambda/delegate as default value for member function argument "cannot be struct members"
https://issues.dlang.org/show_bug.cgi?id=21003 --- Comment #1 from Stanislav Blinov --- Further reduction, `bar` doesn't need to be a template, e.g. struct S { void foo(int value) { bar(() => value); } void bar(int delegate() dg = () => 0) { import std.stdio; writeln(dg()); } } bug.d(8): Error: delegate bug.S.__lambda3 cannot be struct members --
[Issue 21003] Lambda/delegate as default value for member function argument "cannot be struct members"
https://issues.dlang.org/show_bug.cgi?id=21003 Stanislav Blinov changed: What|Removed |Added Summary|Lambda/delegate as default |Lambda/delegate as default |value for member function |value for member function |template argument "cannot |argument "cannot be struct |be struct members" |members" --
[Issue 8904] ld error: `undefined reference to X`
https://issues.dlang.org/show_bug.cgi?id=8904 Basile-z changed: What|Removed |Added Status|NEW |RESOLVED CC||b2.t...@gmx.com Resolution|--- |WORKSFORME --- Comment #4 from Basile-z --- no linker error on braddr tester when trying to revert --
[Issue 21003] New: Lambda/delegate as default value for member function template argument "cannot be struct members"
https://issues.dlang.org/show_bug.cgi?id=21003 Issue ID: 21003 Summary: Lambda/delegate as default value for member function template argument "cannot be struct members" Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: normal Priority: P1 Component: dmd Assignee: nob...@puremagic.com Reporter: stanislav.bli...@gmail.com struct S { void foo(int value) { bar(() => value); } void bar(Dg)(Dg dg = () => 0) { import std.stdio; writeln(dg()); } } In the above, the call to `bar` inside `foo` fails to compile with: bug.d(8): Error: delegate bug.S.bar(Dg)(Dg dg = () => 0) cannot be struct members --
[Issue 21002] New: make std.exception enforce dip1008 agnostic
https://issues.dlang.org/show_bug.cgi?id=21002 Issue ID: 21002 Summary: make std.exception enforce dip1008 agnostic Product: D Version: D2 Hardware: x86_64 OS: Other Status: NEW Severity: enhancement Priority: P1 Component: phobos Assignee: nob...@puremagic.com Reporter: bcarnea...@gmail.com >From a perusal of phobos exception.d it appears that enforce can be made dip 1008 friendly by specialization of the bailOut routine (line 512 currently) and its caller (line 437 currently). Secondarily, it also appears that such specialization could avoid an .idup. --
[Issue 21001] New: Private alias becomes public if used before declaration
https://issues.dlang.org/show_bug.cgi?id=21001 Issue ID: 21001 Summary: Private alias becomes public if used before declaration Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW Severity: normal Priority: P1 Component: dmd Assignee: nob...@puremagic.com Reporter: default_357-l...@yahoo.de Consider the following code ( https://run.dlang.io/is/mn75WZ ): --- a.d module a; private struct S { Alias member; } private alias Alias = int; --- b.d module b; import a; void main() { Alias var; } -- Clearly this shouldn't ought to compile, but it does. Alias is publically visible as an export from a, despite being declared private. This only seems to happen if S comes before Alias. Somehow, using the symbol early prevents it from being marked private. --
[Issue 21000] -preview=nosharedaccess precludes use of stdin,stdout,stderr
https://issues.dlang.org/show_bug.cgi?id=21000 --- Comment #1 from Bruce Carneal --- main() needs a closing brace. --
[Issue 21000] New: -preview=nosharedaccess precludes use of stdin,stdout,stderr
https://issues.dlang.org/show_bug.cgi?id=21000 Issue ID: 21000 Summary: -preview=nosharedaccess precludes use of stdin,stdout,stderr Product: D Version: D2 Hardware: x86_64 OS: Other Status: NEW Severity: enhancement Priority: P1 Component: phobos Assignee: nob...@puremagic.com Reporter: bcarnea...@gmail.com import std.stdio; void main() { writeln("Hello world!"); Compilation of the above with -preview=nosharedaccess fails. The three error messages, one each for stdin, stdout and stderr, look like this: /dlang/dmd/linux/bin64/../../src/phobos/std/stdio.d-mixin-4841(4841): Error: direct access to shared stdin is not allowed, see core.atomic In the current stdio.d, the offending mixin is at line 4858 within the property template named "makeGlobal". The fix may be as simple as a cast at that location. --
[Issue 8904] ld error: `undefined reference to X`
https://issues.dlang.org/show_bug.cgi?id=8904 Dlang Bot changed: What|Removed |Added Keywords||pull --- Comment #3 from Dlang Bot --- @NilsLankila created dlang/phobos pull request #7549 "fix issue 8904 - disable workaround prevent linking issue" fixing this issue: - fix issue 8904 - disable workaround prevent linking issue https://github.com/dlang/phobos/pull/7549 --
[Issue 20981] Runtime segfault for inlined __simd_sto
https://issues.dlang.org/show_bug.cgi?id=20981 Dlang Bot changed: What|Removed |Added Status|REOPENED|RESOLVED Resolution|--- |FIXED --- Comment #4 from Dlang Bot --- dlang/dmd pull request #11347 "fix Issue 20981 - Segfault for inlined __simd_sto" was merged into master: - 097051d0fbe3b5969ef74bac390dec07e6732092 by Walter Bright: fix Issue 20981 - Segfault for inlined __simd_sto https://github.com/dlang/dmd/pull/11347 --
[Issue 20998] error in static struct initialization causes wrong position for subsequent members, producing extra errors
https://issues.dlang.org/show_bug.cgi?id=20998 moonlightsenti...@disroot.org changed: What|Removed |Added CC||moonlightsentinel@disroot.o ||rg --- Comment #1 from moonlightsenti...@disroot.org --- Digger blames this PR: https://github.com/dlang/dmd/pull/2605 --
[Issue 20999] autotester for Darwin_64_64 randomly times out and fails
https://issues.dlang.org/show_bug.cgi?id=20999 Walter Bright changed: What|Removed |Added Keywords||TestSuite --
[Issue 20999] New: autotester for Darwin_64_64 randomly times out and fails
https://issues.dlang.org/show_bug.cgi?id=20999 Issue ID: 20999 Summary: autotester for Darwin_64_64 randomly times out and fails Product: D Version: D2 Hardware: x86_64 OS: Mac OS X Status: NEW Severity: normal Priority: P1 Component: dmd Assignee: nob...@puremagic.com Reporter: bugzi...@digitalmars.com What it should do instead is retry it at least once. This one passed when I manually deprecated it so it would retry. Here's the log: - HOST_DC=/Users/braddr/sandbox/at-client/release-build/dmd-2.079.0/osx/bin/dmd make -C src -f posix.mak auto-tester-build ENABLE_RELEASE=1 posix.mak:75: == Use HOST_DMD instead of HOST_DC == /Users/braddr/sandbox/at-client/release-build/dmd-2.079.0/osx/bin/dmd -of../generated/build -g build.d Warning: Syncing file access because of OSX! ../generated/build HOST_DMD="/Users/braddr/sandbox/at-client/release-build/dmd-2.079.0/osx/bin/dmd" CXX="c++" OS=osx BUILD=release MODEL=64 AUTO_BOOTSTRAP="" DOCDIR="" STDDOC="" DOC_OUTPUT_DIR="" MAKE="make" --called-from-make auto-tester-build (TX) VERSION (TX) SYSCONFDIR (DC) BACKEND Toolchain Information SYSTEM (uname): Darwin macair 15.6.0 Darwin Kernel Version 15.6.0: Thu Jun 21 20:07:40 PDT 2018; root:xnu-3248.73.11~1/RELEASE_X86_64 x86_64 MAKE (make): GNU Make 3.81 Copyright (C) 2006 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. This program built for i386-apple-darwin11.3.0 SHELL (/bin/sh): GNU bash, version 3.2.57(1)-release (x86_64-apple-darwin15) Copyright (C) 2007 Free Software Foundation, Inc. HOST_DMD (/Users/braddr/sandbox/at-client/release-build/dmd-2.079.0/osx/bin/dmd): DMD64 D Compiler v2.079.0 Copyright (C) 1999-2018 by The D Language Foundation, All Rights Reserved written by Walter Bright HOST_CXX (c++): Apple LLVM version 8.0.0 (clang-800.0.42.1) Target: x86_64-apple-darwin15.6.0 Thread model: posix InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin ld (ld): @(#)PROGRAM:ld PROJECT:ld64-274.2 configured to support archs: i386 x86_64 x86_64h armv6 armv7 armv7s armv7m armv7k arm64 (tvOS) LTO support using: LLVM version 8.0.1 gdb (gdb): Toolchain Information (DC) LEXER (TX) DMD_CONF (GIT) DLANG/TOOLS (CXX) CXX-FRONTEND (RUN) checkwhitespace (DC) DMD (DMD) CXX-UNITTEST (RUN) CXX-UNITTEST Success /Applications/Xcode.app/Contents/Developer/usr/bin/make -C src -f posix.mak all posix.mak:75: == Use HOST_DMD instead of HOST_DC == ../generated/build HOST_DMD="/Users/braddr/sandbox/at-client/release-build/dmd-2.079.0/osx/bin/dmd" CXX="c++" OS=osx BUILD=release MODEL=64 AUTO_BOOTSTRAP="" DOCDIR="" STDDOC="" DOC_OUTPUT_DIR="" MAKE="/Applications/Xcode.app/Contents/Developer/usr/bin/make" --called-from-make dmd timed out after 1800 seconds, step failed --
[Issue 20998] New: error in static struct initialization causes wrong position for subsequent members, producing extra errors
https://issues.dlang.org/show_bug.cgi?id=20998 Issue ID: 20998 Summary: error in static struct initialization causes wrong position for subsequent members, producing extra errors Product: D Version: D2 Hardware: All OS: All Status: NEW Keywords: diagnostic Severity: regression Priority: P1 Component: dmd Assignee: nob...@puremagic.com Reporter: elpenguin...@gmail.com ``` struct X { void* ptr; int x; } X x = { invalid, 2 }; ``` This code correctly produces "Error: undefined identifier invalid" but then produces an unexpected "Error: cannot implicitly convert expression 2 of type int to void*". This code should only produce the first error. This incorrect behaviour appears to have been introduced at some point between DMD 2.063 and 2.064. --
[Issue 20996] -preview=dip1021 ICE given one liner throw program
https://issues.dlang.org/show_bug.cgi?id=20996 Basile-z changed: What|Removed |Added Keywords||ice --
[Issue 20997] New: Missing example of scope guard executing after return statement
https://issues.dlang.org/show_bug.cgi?id=20997 Issue ID: 20997 Summary: Missing example of scope guard executing after return statement Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: enhancement Priority: P1 Component: dlang.org Assignee: nob...@puremagic.com Reporter: simen.kja...@gmail.com As pointed out on the forum[0], the documentation[1] for scope guards should include an example with a return statement. Something like this: import std.stdio; int fun() { scope (exit) writeln("Scope guard"); return gun(); } int gun() { writeln("Inside gun()"); return 3; } Will print: Inside gun() Scope guard [0]: https://forum.dlang.org/thread/qzhhdjqvjxsycuxjd...@forum.dlang.org [1]: https://dlang.org/spec/statement.html#scope-guard-statement --